

* {
    box-sizing: border-box;
}


:root {
    --primary: #f57c21;
	--orange: #f57c21;
    --secondary: #7bbf3f;
    --bg: #fffaf3;
    --text: #333;
}

body {
    margin: 0;
    font-family: "Segoe UI", Arial, sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
}

/* ================= HEADER – PROLÍNÁNÍ FOTEK ================= */


header {
    position: relative;
    height: 490px;
    overflow: hidden;
    color: white;
}

/* horní vystřižený papír */
header::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    background: url("../img/ink-top-edge.svg") no-repeat top center;
    background-size: 100% 100%;
    z-index: 5;
    pointer-events: none;
}





.header-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  animation: slideFadeZoom 18s infinite;
}
@keyframes slideFadeZoom {
  0% {
    opacity: 0;
    transform: scale(1.05);
  }
  15% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
  65% {
    opacity: 0;
    transform: scale(0.98);
  }
  100% {
    opacity: 0;
    transform: scale(0.98);
  }
}

.header-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at center,
    rgba(0,0,0,0.0) 0%,
    rgba(0,0,0,0.25) 100%
  );
  pointer-events: none;
}


.header-slide:nth-child(1) {
    background-image: url("../img/header1.jpg");
    animation-delay: 0s;
}

.header-slide:nth-child(2) {
    background-image: url("../img/header2.jpg");
    animation-delay: 6s;
}

.header-slide:nth-child(3) {
    background-image: url("../img/header3.jpg");
    animation-delay: 12s;
}

.header-slide:nth-child(4) {
    background-image: url("../img/header4.jpg");
    animation-delay: 18s;
}


@keyframes slideFade {
  0%   { opacity: 0; }
  15%  { opacity: 1; }
  50%  { opacity: 1; }
  65%  { opacity: 0; }
  100% { opacity: 0; }
}

/* ================= ODKAZ KE STAŽENÍ (BEZ ČÁRY) ================= */

.link-underline {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    font-size: 1.1rem;
    font-weight: 600;

    color: var(--text);
    text-decoration: none;

    transition: color 0.25s ease;
}

/* změna barvy při hoveru */
.link-underline:hover {
    color: var(--primary);   /* ✅ hezká oranžová */
}

/* PDF ikona */
.link-underline .pdf-icon {
    font-size: 1.3em;
    line-height: 1;

    transition:
        transform 0.25s ease,
        color 0.25s ease;
}

/* jemné „oživení“ ikony */
.link-underline:hover .pdf-icon {
    transform: translateY(-1px);
    color: var(--primary);
}


/* ================= KONTAKT – IKONA + TEXT V JEDNOM ŘÁDKU ================= */

.contact-links {
    display: flex;
    flex-direction: column; /* jednotlivé kontakty pod sebou */
    gap: 10px;
    margin-top: 18px;
}

.contact-link {
    display: inline-flex;     /* ✅ IKONA + TEXT VEDLE SEBE */
    align-items: center;
    gap: 10px;

    text-decoration: none;
    color: var(--text);
    font-size: 1.1rem;
    font-weight: 600;

    transition:
        color 0.25s ease,
        transform 0.25s ease;
}

.contact-link-icon {
    font-size: 1.6rem;
    line-height: 1;
}

.contact-link:hover {
    color: var(--primary);     /* oranžová */
    transform: translateX(3px);
}


/* ================= HLAVIČKA – OBSAH ================= */



/* ================= TITULNÍ BOX V HLAVIČCE ================= */

.header-title-box {
    position: relative;

    background: var(--bg); /* ✅ stejná barva jako stránka */
    backdrop-filter: none; /* ❌ vypnout blur */

    box-shadow: none;

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

    padding: 14px 0;

    z-index: 10;
}


.header-title-box h1 {
    font-size: 3.5rem;     /* ⬅️ TADY zvětšíš název */
    line-height: 1.15;
    margin: 0;
    white-space: nowrap;
	min-width: 0;
    color: white;
    text-shadow:
        -1px -1px 0 rgba(0,0,0,0.9),
         1px -1px 0 rgba(0,0,0,0.9),
        -1px  1px 0 rgba(0,0,0,0.9),
         1px  1px 0 rgba(0,0,0,0.9),
         0  2px 6px rgba(0,0,0,0.5);
}


/* ✅ mobil – povol zalomení hlavního nadpisku*/
@media (max-width: 768px) {
  .header-title-box h1 {
    white-space: normal;
     text-align: center;
  }
}




/* menší informace pod názvem */
.header-subinfo {
    margin: 0;               
    font-size: 0.95rem;
    font-weight: 600;
    color: black;

    display: flex;
    justify-content: center;
    gap: 8px;
}



.header-title-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 30px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;                
    text-align: center;
}


.header-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: auto;
    padding: 30px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.header-content h1 {
    font-size: 2.8rem;
    margin: 0;
    text-shadow:
        -1px -1px 0 rgba(0,0,0,0.6),
         1px -1px 0 rgba(0,0,0,0.6),
        -1px  1px 0 rgba(0,0,0,0.6),
         1px  1px 0 rgba(0,0,0,0.6),
         0  0  6px rgba(255,255,255,0.25),
         0  0 14px rgba(255,255,255,0.18),
         0  4px 12px rgba(0,0,0,0.4);
}

/* ================= LOGO – ZÁKLAD ================= */

.logo {
    width: 160px;
    background: white;
    padding: 15px;
    border-radius: 30px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.35);
    display: block;
    margin: 0 auto 20px;
}


/* řádek: logo + název školy */
.header-title-row {
    display: flex;
    align-items: center;   /* vertikálně na střed */
    justify-content: center;
    gap: 12px;
}

/* logo bez bílého oválu – cca o 50 % menší */
.header-logo-plain {
    height: 61px;          /* můžeš doladit: 38–48 px */
    width: auto;

    background: none;
    padding: 0;
    box-shadow: none;
    border-radius: 0;
}

/* ===================== LOGO ZAČÁTEK ===================== */

/* === STAGE PRO LOGO A POSTAVIČKY === */
.logo-stage {
  position: relative;
  width: fit-content;
  margin: 0 auto 10px;
}

/* === LOGO (ŠKOLKA / BUDOVA) === */
.section-logo {
  display: block;
  max-width: 160px;
  margin: 12px auto 28px;
  height: auto;

  position: relative;
  z-index: 3; /* logo je mezi dětmi */

  filter: drop-shadow(0 6px 16px rgba(0,0,0,0.25));
}



/* ===================== LOGO KONEC ===================== */

/* ================= MENU ================= */

nav {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255,255,255,0.65);
    backdrop-filter: blur(4px);
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    padding: 12px;
    text-align: center;
}


nav a {
    margin: 0 10px;
    padding: 8px 14px;
    text-decoration: none;
    font-weight: 600;
    color: var(--text);
    border-radius: 20px;
    transition: all 0.3s ease;
}

/* HOVER + AKTIVNÍ POLOŽKA MENU */
nav a:hover,
nav a.active {
    background-color: var(--secondary);
    color: white;
}


/* ================= ČÁRA NAD MENU ================= */
.header-divider {
    height: 2px;                 /* tloušťka čáry */
    width: 100%;

    background: linear-gradient(
        to right,
        var(--secondary),
        var(--primary),
        var(--secondary)
    );

    box-shadow:
        0 2px 6px rgba(0,0,0,0.25);

    position: relative;
    z-index: 5;
}


/* krátká přechodová čára – uvnitř obsahu */
.divider-mini {
    width: 90%;
    height: 1px;
    margin: 20px auto;

    background: linear-gradient(
        to right,
        var(--secondary),
        var(--primary),
        var(--secondary)
    );

    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}



/* === WOW FOTOKOLÁŽ === */

.photo-collage {
  position: relative;
  max-width: 900px;
  height: 380px;
  margin: 60px auto;
}

.collage-img {
  position: absolute;
  width: 260px;
  height: 180px;
  object-fit: cover;

  border-radius: 18px;
  box-shadow: 0 15px 35px rgba(0,0,0,0.22);

  transition: transform 0.35s ease, box-shadow 0.35s ease;
  cursor: pointer;
}

/* ROZLOŽENÍ FOTEK */
.img-1 { top: 0; left: 50px; transform: rotate(-6deg); }
.img-2 { top: 40px; right: 60px; transform: rotate(5deg); }
.img-3 { top: 120px; left: 200px; transform: rotate(2deg); }
.img-4 { bottom: 0; left: 80px; transform: rotate(-3deg); }
.img-5 { bottom: 40px; right: 120px; transform: rotate(4deg); }

/* HOVER EFEKT */
.collage-img:hover {
  z-index: 10;
  transform: scale(3.22) rotate(0deg);
  box-shadow: 0 35px 80px rgba(0,0,0,0.45);
}

/* === MOBILNÍ VERZE === */
@media (max-width: 768px) {
  .photo-collage {
    height: auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 16px;
  }

  .collage-img {
    position: static;
    width: 100%;
    height: 160px;
    transform: none !important;
  }
}


/* ================= CONTENT, texts etc. ================= */
.container {
    max-width: 1100px;
    margin: auto;
    padding: 20px 20px 50px;

}

.section {
    margin-bottom: 50px;
}

.section h2 {
    text-align: center;
    font-size: 2.1rem;
    color: var(--secondary);
	margin-top: 0;
    margin-bottom: 15px;
}


.high-light-green {
    font-size: 2.1rem;
    font-weight: 700;
    color: var(--secondary);
    text-align: center;
    margin-bottom: 15px;
}

.high-light-orange {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--orange);
    text-align: center;
    margin-bottom: 15px;
}



.simple-text {
    max-width: 800px;
    margin: 0 auto 40px;
    text-align: center;

    /* typografie */
    font-size: 1.1rem;
    line-height: 1.65;
    color: var(--text);
}

.list-text {
    max-width: 800px;
    margin: 0 auto 40px;
    padding-left: 0;
    list-style: none;
    font-size: 1.05rem;
    line-height: 1.65;
    color: var(--text);
	text-align: left;
}

.list-text li {
    position: relative;
    padding-left: 28px;
    margin-bottom: 12px;
}

/* vlastní oranžová odrážka */
.list-text li::before {
    content: "•";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--primary); /* ✅ ORANŽOVÁ */
    font-size: 1.4rem;
    line-height: 1;
}


/* ================= MOTTO – LOGO + BUBLINA ================= */

/* animace přiletění (zůstává stejná) */
@keyframes owlFlyIn {
    0% {
        transform: translateX(-120px) scale(0.7);
        opacity: 0;
    }
    60% {
        transform: translateX(10px) scale(1.05);
        opacity: 1;
    }
    100% {
        transform: translateX(0) scale(1);
        opacity: 1;
    }
}

@keyframes mottoFlyIn {
    from {
        transform: translateX(60px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.motto-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin: 20px auto 30px;
}


.motto-icon {
    font-size: 6rem;          /* ✅ VĚTŠÍ SOVA (zkus 5.5–7rem) */
    line-height: 1;
    font-style: normal;

    animation: owlFlyIn 1.2s ease-out both;
}



.motto-logo {
    width: 110px;
    margin: 0;
    animation: owlFlyIn 1.2s ease-out both;
}

.motto-pill {
    display: inline-flex;
    align-items: center;
    padding: 10px 26px;
    border-radius: 999px;
    background: white;
    color: var(--text);
    font-size: 1.2rem;
    font-style: italic;
    box-shadow: 0 6px 16px rgba(0,0,0,0.1);
    animation: mottoFlyIn 0.8s ease-out both;
    animation-delay: 0.6s;
    position: relative;
}

.motto-pill::before {
    content: "";
    position: absolute;
    left: -8px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    background: white;
    border-radius: 50%;
}

.motto-label {
    font-weight: 700;
    color: var(--primary);
    margin-right: 6px;
    font-style: normal;
}

/* ================= KARTY ================= */

.school-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(280px, 1fr));
    gap: 30px;
    justify-content: center;
    max-width: 800px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .school-cards {
        grid-template-columns: 1fr;
        max-width: 460px;
    }
}


.school-card {
    background: white;
    border-radius: 25px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.school-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.school-card .text {
    padding: 25px;
	text-align: center;
	font-size: 1.1rem;   /* ~16.8 px */
    line-height: 1.45;

}



/* ================= SOCIÁLNÍ IKONY ================= */

.card-social {
    margin-top: 16px;
	margin-bottom: 80px;
    display: flex;
    justify-content: center;
    gap: 12px;
}

.card-social a {
    width: 64px;
    height: 64px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 16px rgba(0,0,0,0.12);
    opacity: 0;
    transform: translateY(30px);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card-social.is-visible a {
    animation: socialItemIn 0.6s ease-out forwards;
}

.card-social.is-visible a:nth-child(2) { animation-delay: 0.15s; }
.card-social.is-visible a:nth-child(3) { animation-delay: 0.3s; }

.card-social a:hover {
    transform: translateY(-6px) scale(1.1);
    box-shadow: 0 14px 30px rgba(0,0,0,0.25);
}

@keyframes socialItemIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}



/* === KONTAKT – IKONA U NADPISU === */

.contact-title {
    display: flex;
    align-items: center;
    justify-content: center; /* ✅ centrování celé hlavičky */
    gap: 12px;
}

.contact-icon {
    display: inline-block;
    font-size: 5rem;
    opacity: 0;
    transform: translateX(-40px) rotate(-10deg);
    animation: bear-fly-in 0.9s ease-out forwards;
}

/* Animace medvídka */
@keyframes bear-fly-in {
    0% {
        opacity: 0;
        transform: translateX(-40px) rotate(-10deg);
    }

    70% {
        opacity: 1;
        transform: translateX(6px) rotate(3deg);
    }

    100% {
        opacity: 1;
        transform: translateX(0) rotate(0);
    }
}



/* === VODOTISK LOGA JEN NA STRÁNCE KONTAKT === */

.page-contact .school-card {
    position: relative;   /* klidně zůstane */
    max-width: 800px;     /* ⬅️ TADY je klíč */
    margin: 0 auto;       /* ⬅️ centrování */
}


.page-contact .school-card::after {
    content: "";
    position: absolute;

    right: 32px;
    top: 50%;
    transform: translateY(-50%);

    width: 160px;
    height: 160px;

    background-image: url("../img/logo.png");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;

    opacity: 1.00;           /* ✅ KLÍČOVÉ – konečně viditelné */
    pointer-events: none;
}



@media (max-width: 768px) {
    .page-contact .school-card::after {
        display: none;
    }
}



/* ================= FOOTER ================= */

footer {
    background: #f1f1f1;
    text-align: center;
    padding: 20px;
    font-size: 0.9rem;
}

/* FB / WA / IG bubliny pod kartou */

.card-social {
    margin-top: 16px;
    display: flex;
    justify-content: center;
    gap: 12px;
}

/* výchozí stav – IKONY JSOU SKRYTÉ */
.card-social a {
    width: 64px;
    height: 64px;
    background: white;
    border-radius: 50%;

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

    box-shadow: 0 6px 16px rgba(0,0,0,0.12);

    /* klíčové pro animaci při scrollu */
    opacity: 0;
    transform: translateY(30px);

    /* plynulý hover */
    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease;
}

/* animace po zobrazení při scrollu */
.card-social.is-visible a {
    animation: socialItemIn 0.6s ease-out forwards;
}

/* postupné zpoždění */
.card-social.is-visible a:nth-child(1) { animation-delay: 0s; }
.card-social.is-visible a:nth-child(2) { animation-delay: 0.15s; }
.card-social.is-visible a:nth-child(3) { animation-delay: 0.3s; }

/* HOVER – zvětšení + vytažení */
.card-social a:hover {
    transform: translateY(-6px) scale(1.1);
    box-shadow: 0 14px 30px rgba(0,0,0,0.25);
}

.card-social img {
    width: 38px;
    height: 38px;
    display: block;
}


@media (max-width: 768px) {
  body {
    zoom: 0.9;
  }
}

@media (max-width: 768px) {

  /* ===== HEADER ===== */
  header {
    height: 300px; /* jemně vyšší než 280, ať header dýchá */
  }

  header::after {
    height: 56px; /* menší výška pastelkového horního okraje na mobilu */
    background-size: 100% 100%;
  }

  .header-title-box {
    background: var(--bg);
    padding: 10px 12px;
  }

  .header-title-inner {
    padding: 0 14px;
    gap: 6px;
  }

  .header-title-row {
    gap: 8px;
  }

  .header-logo-plain {
    height: 44px;
  }

  .header-title-box h1 {
    font-size: 1.6rem;
    line-height: 1.2;
    white-space: normal;
    text-align: center;
  }

  .header-title-box h1 br {
    display: none;
  }

  .header-subinfo {
    font-size: 0.82rem;
    line-height: 1.35;
    text-align: center;
    justify-content: center;
    gap: 4px;
    flex-wrap: wrap;
  }

  /* ===== MENU ===== */
  nav {
    padding: 10px 6px;
  }

  nav a {
    margin: 4px;
    padding: 6px 10px;
    font-size: 0.95rem;
  }
}

/* ===============================
   AKTUALITY – NÁHLEDOVÝ OBRÁZEK
=============================== */

.article-image-wrap {
    margin-top: 18px;
    display: flex;
    justify-content: center;
}

.article-image {
    width: 100%;
    max-width: 320px;      /* ⬅️ menší náhled */
    border-radius: 16px;
    box-shadow: 0 8px 22px rgba(0,0,0,0.18);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

/* ✨ jemný WOW hover */
.article-image:hover {
    transform: scale(1.03);
    box-shadow: 0 18px 42px rgba(0,0,0,0.28);
}

/* 📱 mobilní verze */
@media (max-width: 768px) {
    .article-image {
        border-radius: 14px;
    }
}

/* ===============================
   ODKAZ „VÍCE“ – ORANŽOVÝ AKCENT
=============================== */
.read-more {
    color: #f57c21;
    font-weight: 600;
	letter-spacing: 0.2px;
    text-decoration: none;
    font-size: 0.95rem;

    margin-top: 10px;
    align-self: flex-start;
	
	transition: transform 0.25s ease, color 0.25s ease;
	display: inline-block;
}

/* název přílohy v DETAILU novinky – černá barva */
.news-card .section-label + ul .read-more {
    color: #000;          /* černá */
    font-weight: 550;     /* normální váha, nepřebíjí ikonu */
}



.read-more:hover {
    
    transform: translateX(3px);
    color: #e66f1d;
	font-weight: 700; 

}

/* ✅ přílohy – bez posunu */
.news-card ul li a.read-more:hover {
    transform: none;        /* ❌ zruší pohyb */
    color: var(--primary);  /* ✅ jen barva */
}


/* ===== NOVINKY – WOW NÁHLED ===== */

.news-card {
    position: relative;
    max-width: 800px;
    margin: 0 auto 32px;

    min-height: 220px;

    padding: 24px;
    padding-right: 220px;

    background: #fffdf8; /* místo čistě bílé – jemně teplejší */
    border-radius: 24px;
    box-shadow:
        0 8px 22px rgba(0,0,0,0.10),
        0 3px 10px rgba(245,124,33,0.06);

    overflow: hidden;

    display: flex;
    flex-direction: column;

    transform: translateZ(0);
}

/* text */
.news-card p {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

/* datum */
.news-card small {
    display: inline-block;
    width: fit-content;

    margin-bottom: 14px;
    padding: 5px 12px;

    background: #fff3df;
    color: #8b6a3d;
    border-radius: 999px;

    font-size: 0.9rem;
    font-weight: 600;
}



/* dlouhé titulky se nerozbijí */

.news-card h3 {
    color: #7bbf3f;
    margin-top: 0;
    font-size: 1.7rem;
    margin-bottom: 6px;
    position: relative;
}






.news-card--detail h3 {
    overflow: visible;
    text-overflow: unset;
    white-space: normal;     /* ✅ dovolí více řádků */
	line-height: 1.25;
}





/* ✅ wrapper – drží pevnou velikost a ořez */
.news-image-wrap {
    position: absolute;
    top: 0;
    right: 0;

    width: 200px;
    height: 100%;

    overflow: hidden;                 /* ✅ KLÍČ */
    border-radius: 0 24px 24px 0;
}

/* ✅ obrázek uvnitř */
.news-image-big {
    width: 100%;
    height: 100%;
    object-fit: cover;

    transition: transform 0.3s ease, filter 0.3s ease;
}

/* ✅ hover efekt – zoom uvnitř (už NEPŘETEČE) */
.news-image-wrap:hover .news-image-big {
    transform: scale(1.05);
    filter: brightness(1.1);
}
/* ✅ DETAIL NOVINKY – dělící barevná čára */
.news-card::before {
    content: "";
    position: absolute;

    top: 0;           /* ✅ od úplného vrchu */
    bottom: 0;        /* ✅ až dolů */

    right: 200px;     /* podle šířky obrázku */

    width: 2px;

    background: linear-gradient(
        to bottom,
        var(--secondary),
        var(--primary),
        var(--secondary)
    );

    box-shadow: 0 2px 6px rgba(0,0,0,0.25);

    z-index: 2;
    pointer-events: none;
}

.news-card--detail::before {
    display: none;
}


/* ✅ DETAIL NOVINKY – základní reset (platí pro všechny) */
.news-card.news-card--detail {
    padding: 24px !important;        /* ✅ reset layoutu */

    min-height: unset !important;
    height: auto !important;

    display: block !important;
}

/* ✅ FIX GLITCHE – jen pro první kartu */
.section > .news-card--detail:first-of-type {
    transform: translateZ(0);
}

/* ✅ BONUS – rozbití margin collapsing */
.news-card--detail {
    margin-top: 1px;
}




/* kontejner ikon vpravo dole */
.news-icons {
    position: absolute;
    right: 220px;   /* ✅ POSUN O ŠÍŘKU OBRÁZKU */
    bottom: 18px;

    display: flex;
    gap: 10px;
    align-items: center;
}

/* ================================================= */
/* ============ PŘÍLOHY V DETAILU ================== */
/* ================================================= */

/* seznam příloh – bez klasických odrážek */
.news-card ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

/* jeden řádek přílohy: ikona + text */
.news-card li {
    display: flex;
    align-items: center;     /* ⬅️ svislé vycentrování */
    gap: 6px;
    margin-bottom: 6px;
}

/* ikona dokumentu 📄 – BEZ SHADOW */
.attachment-icon {
    font-size: 1.3rem;       /* velikost ikony */
    line-height: 1;
    color: #f57c21;          /* školková oranžová */
}




/* 🖼 VĚTŠÍ NÁHLED OBRÁZKU */
.news-thumb {
    width: 64px;              /* ⬅️ větší náhled */
    height: 64px;
    border-radius: 14px;     /* jemně zaoblený čtverec */
    overflow: hidden;
    border: 2px solid #fff;
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
}

.news-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== NOVINKY – ZELENÉ TITULKY ===== */

.news-card h3 {
    color: #7bbf3f;
    margin-top: 0;
    font-size: 1.7rem;
    margin-bottom: 10px;

    position: relative;
    display: inline-block;   /* ✅ podtržení jen pod textem */
    width: fit-content;
}

.news-card::after {
    display: none;
    content: none;
}

.news-card h3 {
    color: #7bbf3f;
    margin-top: 0;
    font-size: 1.7rem;
    margin-bottom: 16px;   /* ✅ trochu víc místa pod nadpisem */
    position: relative;
    display: inline-block;
    width: fit-content;
}

.news-card h3::after {
    content: "";
    position: absolute;
    left: 2px;
    bottom: -1px;   /* ✅ bylo -8px, teď je víc pod nadpisem */

    width: 100%;
    height: 2px;

    background:
        linear-gradient(
            to right,
            rgba(123,191,63,0) 0%,
            rgba(123,191,63,0.22) 8%,
            rgba(123,191,63,0.34) 20%,
            rgba(123,191,63,0.28) 38%,
            rgba(123,191,63,0.36) 55%,
            rgba(123,191,63,0.24) 72%,
            rgba(123,191,63,0.30) 88%,
            rgba(123,191,63,0) 100%
        );

    border-radius: 999px;
    transform: none;
    filter: blur(0.2px);
    pointer-events: none;
}

/* === BĚŽNÝ TEXT – STEJNÝ JAKO PŮVODNÍ STATICKÝ WEB === */
.simple-text {
    font-size: 1.1rem;   /* ≈ 16.8px */
    line-height: 1.65;
    color: var(--text);
}

/* === TEXT V NOVINKÁCH (kompaktnější) === */
.news-card p {
    font-size: 16px;
    line-height: 1.6;
}


.news-card--detail p {
    display: block;
    -webkit-line-clamp: unset;
    -webkit-box-orient: unset;

    overflow: visible;
}


/* === DETAIL NOVINKY – PŘÍLOHY (PDF) === */
.news-card ul li {
    transition: color 0.25s ease;
}

/* text odkazu */
.news-card ul li a.read-more {
    color: var(--text);
    text-decoration: none;
    transition: color 0.25s ease;
}

/* ikonka */
.news-card ul li .attachment-icon {
    transition: color 0.25s ease, transform 0.25s ease;
}

/* ✅ HOVER – stejný efekt jako link-underline */
.news-card ul li:hover a.read-more {
    color: var(--primary); /* oranžová */
}

.news-card ul li:hover .attachment-icon {
    color: var(--primary);
    transform: translateY(-1px);
}


/* ===============================
   AKTUALITY – GALERIE OBRÁZKŮ
=============================== */

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 14px;
    margin-top: 24px;
}

.gallery img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 16px;
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.gallery img:hover {
    transform: scale(1.04);
    box-shadow: 0 12px 32px rgba(0,0,0,0.35);
}

@media (max-width: 768px) {
    .gallery {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===============================
   LIGHTBOX GALERIE – WOW EFEKT
=============================== */

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox.hidden {
    display: none;
}

.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.85);
}

.lightbox-image {
    position: relative;
    max-width: 90vw;
    max-height: 85vh;
    border-radius: 18px;
    box-shadow: 0 25px 60px rgba(0,0,0,0.6);
    animation: lightboxZoom 0.25s ease;
    z-index: 2;
}

@keyframes lightboxZoom {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Zavření */
.lightbox-close {
    position: absolute;
    top: 24px;
    right: 30px;
    font-size: 2.2rem;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    z-index: 3;
}

/* Šipky */
.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 4rem;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 10px;
    z-index: 3;
    opacity: 0.85;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    opacity: 1;
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

/* Mobil */
@media (max-width: 768px) {
    .lightbox-prev,
    .lightbox-next {
        font-size: 3rem;
    }
}

/* ===== ADMIN – INFO HLÁŠKY ===== */

.admin-info {
    margin-bottom: 14px;
    padding: 10px 14px;
    background: #fff3cd;
    border: 1px solid #ffeeba;
    border-radius: 10px;
    color: #856404;
    font-weight: 600;
}

.news-attachment {
    text-decoration: none;
	font-size: 1.7rem; 
}

/* ===============================
   DIVIDER – NOVINKY (DETAIL)
=============================== */
.divider-news {
    height: 1px;                 /* tloušťka čáry */
    width: 85%;
	margin: 65px auto 35px; /* 👈 víc prostoru nad i pod */
	background: linear-gradient(
        to right,
        var(--secondary),
        var(--primary),
        var(--secondary)
    );

    box-shadow:
        0 2px 6px rgba(0,0,0,0.25);

    position: relative;
    z-index: 5;
}


/* Popisky sekcí v detailu novinky (Fotogalerie, Přílohy) */
.news-card .section-label {
    font-size: 1.1rem;       /* velikost písma */
    font-weight: 700;
    color: var(--secondary);  /* zelená jako nadpisy */
    margin-bottom: 12px;
}


/* Odkaz zpět v detailu novinky */
.news-back {
    margin-top: 68px; /* 👈 tady zvětšuješ odstup */
}

/* IKONA školky vpravo na kartě NOVINKY */
.news-card--detail {
    position: relative;
}

.news-card--detail::after {
    content: "";
    position: absolute;
    top: 18px;
    right: 18px;
    width: 56px;
    height: 56px;
    background-image: url("../img/logo.png");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    opacity: 0.18;          /* jemné, neruší */
    pointer-events: none;  /* neklikatelné */
}
.news-card--detail h3 {
    margin: 0 0 6px 0;
    padding-right: 0;
    line-height: 1.25;
    display: inline-block;
}

.news-card--detail small {
    display: inline-block;
    margin-left: 10px;   /* ✅ pár mezer od nadpisu */
    margin-bottom: 0;
    vertical-align: middle;

    color: #8b6a3d;
    font-weight: 600;
    font-size: 0.92rem;
    letter-spacing: 0.2px;
    white-space: nowrap;
}


.school-card--narrow {
    max-width: 700px;
    margin: 0 auto;
    text-align: left;
}



/* FOTOGALERIE */

.gallery-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 28px;

    width: 100%;
}


/* ===== KARTA ===== */
.gallery-card {
    text-decoration: none;
    color: inherit;
    display: block;

    background: #ffffff;
    padding: 12px 14px 14px 14px;

    border-radius: 22px;

    box-shadow: 
        0 10px 26px rgba(0,0,0,0.12),
        0 4px 12px rgba(245,124,33,0.12);

    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.gallery-card:hover {
    transform: translateY(-3px);
    box-shadow: 
        0 16px 34px rgba(0,0,0,0.16),
        0 6px 16px rgba(245,124,33,0.18);
}

/* ===== BLOK FOTEK ===== */
.gallery-card-images {
    height: 180px; /* ✅ jedna velká fotka */
    border-radius: 18px;
    overflow: hidden;
    background: #fffaf3;
}

/* ===== OBRÁZKY ===== */
.gallery-card-images img {
    width: 100%;
    height: 100%;
    object-fit: cover;

    border-radius: 12px;

    transition: transform 0.25s ease, filter 0.25s ease;
}

/* jemný micro-zoom */
.gallery-card-images img:hover {
    transform: scale(1.1);
}

/* ztmavení ostatních (už skoro nehraje roli, ale necháme) */
.gallery-card-images:hover img:not(:hover) {
    filter: brightness(0.9);
}

/* ===== TEXT ===== */
.gallery-card-info {
    margin-top: 10px;
    text-align: center;
}

.gallery-card-info h3 {
    margin: 0 auto 10px;
    font-size: 1.05rem;
    position: relative;
    display: block;
    width: fit-content;
}

.gallery-card-info h3::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -6px;
    transform: translateX(-50%);

    width: clamp(70px, 28vw, 120px);
    height: 1px;   /* ✅ tenčí */

    background: linear-gradient(
        to right,
        rgba(123,191,63,0) 0%,
        rgba(123,191,63,0.9) 20%,
        rgba(245,124,33,0.95) 50%,
        rgba(123,191,63,0.9) 80%,
        rgba(123,191,63,0) 100%
    );

    border-radius: 999px;
    pointer-events: none;
}

.gallery-card-info small {
    display: block;
}
``

.gallery-card-info small {
    color: #666;
}

.page-layout {
    min-height: 100vh;
    display: block; 
    flex-direction: column;
}

.page-layout .container {
    flex: 1;
    width: 100%;
}


.gallery-count {
    display: block;
    font-size: 0.9rem;
    color: #888;
    margin-top: 2px;
}



/* FOTOGALERIE KONEC */

@media (max-width: 768px) {

    .container {
        padding-left: 10px;
        padding-right: 10px;
    }

    .gallery {
        margin-left: -10px;
        margin-right: -10px;
    }

    /* ✅ NOVINKY – sjednoceno */
    .news-card {
        padding: 20px !important;
        padding-right: 130px !important;

        max-width: 100% !important;
        box-sizing: border-box;
    }

    .news-image-wrap {
        width: 130px !important;
    }

    .news-icons {
        right: 130px !important;
    }
	
	
    .news-card::before {
        right: 130px !important;
    }


}
/* ===============================
   HOMEPAGE – POSLEDNÍ NOVINKY
=============================== */

.home-news-teaser {
    padding: 10px 20px 40px;
}

.home-news-inner {
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
}

.home-news-teaser h2 {
    margin-top: 0;
    margin-bottom: 8px;
    color: var(--secondary);
    font-size: 2rem;
}

.home-news-subtitle {
    margin: 0 auto 24px;
    color: #6b6b6b;
    font-size: 1.02rem;
    max-width: 620px;
}

/* ornament / nástěnka */
.home-news-ornament {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 18px;
    flex-wrap: wrap;
    margin: 0 auto 22px;
    min-height: 270px;
}

.home-news-shot {
    position: relative;
    display: block;
    width: 220px;
    height: 190px;
    background: #fff;
    padding: 8px;
    border-radius: 22px;
    box-shadow:
        0 12px 28px rgba(0,0,0,0.12),
        0 4px 12px rgba(245,124,33,0.10);
    overflow: hidden;
    text-decoration: none;
    color: inherit;

    /* přílet při scrollu */
    opacity: 0;
    will-change: transform, opacity;

    /* výchozí stav před zobrazením */
    transform:
        translate(var(--start-x, 0px), var(--start-y, 24px))
        rotate(var(--r, 0deg))
        scale(0.96);

    /* pomalejší přechod pro přílet */
    transition:
        opacity 0.55s ease,
        transform 0.55s ease,
        box-shadow 0.25s ease;
}

.home-news-shot img {
    width: 100%;
    height: calc(100% - 34px);
    object-fit: cover;
    border-radius: 16px;
    display: block;
    transition: transform 0.25s ease; /* jemný zoom obrázku při hoveru */
}


.home-news-shot-title {
    display: block;
    width: 100%;
    max-width: 100%;
    margin-top: 8px;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.25;
    color: var(--text);
    text-align: center;
    padding: 0 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* jemně pootočené "ornamentální" rozložení + směr příletu */
.home-news-shot--1 {
    --r: -4deg;
    --start-x: -34px;
    --start-y: 18px;
}

.home-news-shot--2 {
    width: 250px;
    height: 210px;
    --r: 1.5deg;
    --start-x: 0px;
    --start-y: 30px;
    z-index: 2;
}

.home-news-shot--3 {
    --r: 4deg;
    --start-x: 34px;
    --start-y: 18px;
}

/* po zobrazení */
.home-news-shot.is-visible {
    opacity: 1;
    transform: translate(0, 0) rotate(var(--r, 0deg)) scale(1);
}

/* po příletu přepneme na rychlejší hover */
.home-news-shot.is-hover-ready {
    transition:
        transform 0.22s ease,
        box-shadow 0.22s ease,
        opacity 0.22s ease;
}

/* hover – zachová rotaci a je zase svižný */
.home-news-shot.is-hover-ready:hover {
    transform: translateY(-4px) rotate(var(--r, 0deg)) scale(1.01);
    box-shadow:
        0 16px 34px rgba(0,0,0,0.16),
        0 6px 16px rgba(245,124,33,0.16);
}

.home-news-shot.is-hover-ready:hover img {
    transform: scale(1.03);
}

.home-news-actions {
    margin-top: 50px;
    margin-bottom: 110px;
}

.home-news-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 11px 18px;
    border-radius: 999px;
    text-decoration: none;
    background: #fff3df;
    color: #8b6a3d;
    font-weight: 700;
    box-shadow: 0 8px 18px rgba(245,124,33,0.10);
    transition: transform 0.2s ease, background 0.2s ease;
}

.home-news-link:hover {
    transform: translateY(-2px);
    background: #ffe9c8;
}

/* ===== mobil ===== */
@media (max-width: 768px) {
    .home-news-teaser {
        padding: 0 12px 28px;
    }

    .home-news-teaser h2 {
        font-size: 1.7rem;
    }

    .home-news-subtitle {
        font-size: 0.96rem;
        margin-bottom: 18px;
    }

    .home-news-ornament {
        gap: 12px;
        min-height: unset;
    }

    .home-news-shot,
    .home-news-shot--2 {
        width: 100%;
        max-width: 320px;
        height: 235px;
    }

    .home-news-shot img {
        height: calc(100% - 42px);
    }


    .home-news-shot-title {
        font-size: 0.92rem;
    }

    /* na mobilu menší a rovný přílet */
    .home-news-shot--1,
    .home-news-shot--2,
    .home-news-shot--3 {
        --r: 0deg;
        --start-x: 0px;
        --start-y: 18px;
    }
}


.home-news-divider {
    width: min(650px, 45vw);
    height: 2px;
    margin: 0 auto 18px;

    background: linear-gradient(
        to right,
        var(--secondary),
        var(--primary),
        var(--secondary)
    );

    border-radius: 999px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.12);
    opacity: 0.9;
}
``


/* =====================================================
   WOW EFEKT – 4 KARTIČKY S FOTKAMI A MOTTY
   Přidej až na KONEC souboru, aby přepsal starší styly.
===================================================== */

.school-cards {
    max-width: 920px;
    gap: 34px;
    align-items: stretch;
    perspective: 1200px;
}

.school-card {
    --card-tilt: 0deg;
    position: relative;
    overflow: visible;
    border-radius: 32px;
    padding: 14px 14px 18px;
    background:
        radial-gradient(circle at top left, rgba(245,124,33,0.10), transparent 34%),
        radial-gradient(circle at bottom right, rgba(123,191,63,0.10), transparent 30%),
        linear-gradient(180deg, rgba(255,255,255,0.98), rgba(255,250,243,0.98));
    border: 1px solid rgba(245,124,33,0.10);
    box-shadow:
        0 18px 38px rgba(0,0,0,0.10),
        0 8px 18px rgba(245,124,33,0.10);
    transform: translateY(0) rotate(var(--card-tilt));
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.school-card:nth-child(1) { --card-tilt: -1.6deg; }
.school-card:nth-child(2) { --card-tilt:  1.4deg; }
.school-card:nth-child(3) { --card-tilt:  1.0deg; }
.school-card:nth-child(4) { --card-tilt: -1.2deg; }

/* pastelkový „ručně kreslený“ rámeček nad fotkou */
.school-card::before {
    content: "";
    position: absolute;
    inset: 10px 10px auto;
    height: 214px;
    border-radius: 28px;
    border: 2px dashed rgba(123,191,63,0.36);
    transform: rotate(-1.7deg);
    pointer-events: none;
    z-index: 1;
}

/* dětské cákance / puntíky v rohu */
.school-card::after {
    content: "";
    position: absolute;
    top: -12px;
    right: -12px;
    width: 92px;
    height: 92px;
    pointer-events: none;
    z-index: 3;
    opacity: 0.82;
    background:
        radial-gradient(circle at 20% 22%, rgba(245,124,33,0.28) 0 4px, transparent 5px),
        radial-gradient(circle at 72% 28%, rgba(123,191,63,0.25) 0 4px, transparent 5px),
        radial-gradient(circle at 50% 68%, rgba(85,170,255,0.18) 0 5px, transparent 6px),
        radial-gradient(circle at 82% 72%, rgba(245,124,33,0.18) 0 3px, transparent 4px);
    filter: blur(0.2px);
}

.school-card:hover {
    transform: translateY(-10px) rotate(0deg) scale(1.015);
    border-color: rgba(245,124,33,0.20);
    box-shadow:
        0 28px 56px rgba(0,0,0,0.16),
        0 12px 22px rgba(245,124,33,0.14);
}

.school-card img {
    position: relative;
    z-index: 2;
    display: block;
    width: calc(100% - 28px);
    margin: 14px auto 0;
    height: 220px;
    object-fit: cover;
    border-radius: 24px;
    border: 6px solid rgba(255,255,255,0.92);
    outline: 2px solid rgba(245,124,33,0.16);
    outline-offset: -10px;
    box-shadow:
        0 14px 28px rgba(0,0,0,0.14),
        0 0 0 10px rgba(255,255,255,0.45);
    transition: transform 0.45s ease, filter 0.35s ease, box-shadow 0.35s ease;
}

.school-card:hover img {
    transform: scale(1.04) rotate(0.4deg);
    filter: saturate(1.06) brightness(1.03);
    box-shadow:
        0 18px 34px rgba(0,0,0,0.18),
        0 0 0 10px rgba(255,255,255,0.55);
}

.school-card .text {
    position: relative;
    padding: 22px 22px 12px;
    text-align: center;
}

/* velké jemné uvozovky jako dekorace motta */
.school-card .text::before {
    content: "„";
    position: absolute;
    top: 2px;
    left: 10px;
    font-size: 4.1rem;
    line-height: 1;
    font-family: Georgia, "Times New Roman", serif;
    color: rgba(245,124,33,0.16);
}

.school-card .text p {
    margin: 0;
    position: relative;
    z-index: 1;
    font-size: 1.15rem;
    line-height: 1.62;
    font-weight: 700;
    letter-spacing: 0.01em;
    color: #5a4a32;
    text-wrap: balance;
}

.school-card:nth-child(even) .text p {
    color: #4f6133;
}

/* tenká pastelková čára pod textem */
.school-card .text p::after {
    content: "";
    display: block;
    width: 72px;
    height: 6px;
    margin: 14px auto 0;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(245,124,33,0.0), rgba(245,124,33,0.62), rgba(123,191,63,0.58), rgba(123,191,63,0));
}

/* jemná ručně kreslená linka přes kartičku */
.school-card .text::after {
    content: "";
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 4px;
    height: 22px;
    pointer-events: none;
    opacity: 0.28;
    background:
        radial-gradient(circle at 6% 65%, rgba(245,124,33,0.35) 0 1.5px, transparent 2px),
        radial-gradient(circle at 22% 40%, rgba(123,191,63,0.35) 0 1.5px, transparent 2px),
        radial-gradient(circle at 48% 62%, rgba(245,124,33,0.30) 0 1.5px, transparent 2px),
        radial-gradient(circle at 80% 35%, rgba(123,191,63,0.32) 0 1.5px, transparent 2px),
        linear-gradient(90deg, transparent 0%, rgba(245,124,33,0.22) 22%, rgba(123,191,63,0.20) 52%, rgba(245,124,33,0.16) 80%, transparent 100%);
    border-radius: 999px;
}

@media (max-width: 768px) {
    .school-cards {
        gap: 26px;
    }

    .school-card {
        transform: none;
        padding: 12px 12px 16px;
    }

    .school-card:hover {
        transform: translateY(-4px);
    }

    .school-card::before {
        inset: 8px 8px auto;
        height: 196px;
    }

    .school-card img {
        width: calc(100% - 22px);
        height: 200px;
        margin-top: 11px;
        border-radius: 22px;
    }

    .school-card .text {
        padding: 18px 16px 8px;
    }

    .school-card .text::before {
        font-size: 3.2rem;
        left: 8px;
    }

    .school-card .text p {
        font-size: 1.06rem;
        line-height: 1.55;
    }
}


/* =====================================================
   SCROLL REVEAL + CLICK PREVIEW (STABILNÍ VERZE)
   - karty přiletí až při doscrollování
   - zvětšená karta se otevře po kliknutí
   - zavření klikem mimo kartu nebo klávesou Esc
===================================================== */

.school-cards {
    overflow: visible;
}

/* ================= SCROLL REVEAL ================= */
.school-card.reveal-init {
    opacity: 0;
    will-change: transform, opacity, filter;
    transition:
        transform 0.85s cubic-bezier(.22,.9,.24,1),
        opacity 0.65s ease,
        filter 0.65s ease,
        box-shadow 0.35s ease,
        border-color 0.35s ease;
}

.school-card.reveal-init:nth-child(1) {
    transform: translate3d(-82px, 30px, 0) rotate(-7deg) scale(0.93);
    filter: blur(2px);
}

.school-card.reveal-init:nth-child(2) {
    transform: translate3d(82px, 30px, 0) rotate(7deg) scale(0.93);
    filter: blur(2px);
}

.school-card.reveal-init:nth-child(3) {
    transform: translate3d(-58px, 60px, 0) rotate(-5deg) scale(0.92);
    filter: blur(2px);
}

.school-card.reveal-init:nth-child(4) {
    transform: translate3d(58px, 60px, 0) rotate(5deg) scale(0.92);
    filter: blur(2px);
}

.school-card.reveal-init.is-visible {
    opacity: 1;
    filter: blur(0);
    transform: translate3d(0, 0, 0) rotate(var(--card-tilt, 0deg)) scale(1);
    animation: schoolCardLandingSimple 0.82s cubic-bezier(.19,.89,.24,1.04) both;
}

.school-card.reveal-init.is-visible:nth-child(1) { animation-delay: 0.02s; }
.school-card.reveal-init.is-visible:nth-child(2) { animation-delay: 0.14s; }
.school-card.reveal-init.is-visible:nth-child(3) { animation-delay: 0.26s; }
.school-card.reveal-init.is-visible:nth-child(4) { animation-delay: 0.38s; }

@keyframes schoolCardLandingSimple {
    0% {
        opacity: 0;
    }
    60% {
        transform: translate3d(0, -8px, 0) rotate(calc(var(--card-tilt, 0deg) * -0.18)) scale(1.015);
    }
    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0) rotate(var(--card-tilt, 0deg)) scale(1);
    }
}

.school-card.reveal-init.is-visible:hover {
    transform: translateY(-10px) rotate(0deg) scale(1.015);
}

.school-card {
    cursor: pointer;
}

/* ============== CLICK PREVIEW – STŘED OBRAZOVKY ============== */
.card-preview-overlay {
    position: fixed;
    inset: 0;
    z-index: 9998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
}

.card-preview-overlay.is-visible {
    opacity: 1;
    pointer-events: auto;
}

.card-preview-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(22, 18, 12, 0.32);
    backdrop-filter: blur(10px) saturate(1.04);
}

.card-preview-stage {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 26px;
    pointer-events: none;
}

.card-preview-clone {
    width: min(760px, 92vw);
    max-height: 86vh;
    overflow: visible;
    opacity: 0;
    pointer-events: auto;
    transform:
        translate3d(var(--preview-from-x, 0), var(--preview-from-y, 58px), 0)
        rotate(var(--preview-from-r, 0deg))
        scale(0.72);
    filter: blur(1.5px);
    box-shadow:
        0 34px 90px rgba(0,0,0,0.22),
        0 12px 32px rgba(245,124,33,0.16);
    transition:
        transform 0.42s cubic-bezier(.2,.9,.22,1),
        opacity 0.2s ease,
        filter 0.2s ease;
}

.card-preview-clone.is-visible {
    opacity: 1;
    filter: blur(0);
    transform: translate3d(0, 0, 0) rotate(0deg) scale(1);
}

/* uvnitř preview vypnout všechno, co by vizuálně cukalo */
.card-preview-clone .text,
.card-preview-clone .text p,
.card-preview-clone .text::before,
.card-preview-clone .text::after,
.card-preview-clone .text p::after,
.card-preview-clone img {
    animation: none !important;
}

.card-preview-clone .text {
    transform: none !important;
}

.card-preview-clone .text p {
    transform: none !important;
    opacity: 1 !important;
}

.card-preview-clone img {
    height: min(320px, 38vh);
}

/* když je preview otevřené, potlačíme hover originálu */
body.card-preview-open .school-card:hover {
    transform: translate3d(0, 0, 0) rotate(var(--card-tilt, 0deg)) scale(1);
}

body.card-preview-open {
    overflow-x: hidden;
}

@media (prefers-reduced-motion: reduce) {
    .school-card.reveal-init,
    .school-card.reveal-init.is-visible,
    .card-preview-overlay,
    .card-preview-clone {
        opacity: 1 !important;
        transform: none !important;
        filter: none !important;
        animation: none !important;
        transition: none !important;
    }
}

@media (max-width: 768px) {
    .school-card.reveal-init:nth-child(1),
    .school-card.reveal-init:nth-child(2),
    .school-card.reveal-init:nth-child(3),
    .school-card.reveal-init:nth-child(4) {
        transform: translate3d(0, 40px, 0) rotate(0deg) scale(0.96);
    }

    .school-card.reveal-init.is-visible:hover {
        transform: translateY(-4px) scale(1.01);
    }

    .card-preview-stage {
        padding: 16px;
    }

    .card-preview-clone {
        width: min(96vw, 640px);
    }

    .card-preview-clone img {
        height: min(260px, 34vh);
    }
}
