/* Galéria – óvodás, játékos stílus (az oldal színeihez igazítva) */
:root {
    --g-orange: #EFA53E;
    --g-dark-orange: #DD8C2C;
    --g-red: #E56A3F;
    --g-green: #77BC2A;
    --g-yellow: #EDC45C;
    --g-cream: #FFF8EC;
}

.gallery-wrap {
    background: var(--g-cream);
    border-radius: 40px;
    padding: 40px 24px 50px;
    margin-top: 40px;
    box-shadow: 0 10px 40px rgba(221, 140, 44, .15);
}

.gallery-heading {
    font-family: 'Galindo', sans-serif;
    color: var(--g-red);
    font-size: 26px;
    margin: 0 0 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.gallery-heading::after {
    content: "";
    flex: 1;
    height: 4px;
    border-radius: 4px;
    background: repeating-linear-gradient(90deg, var(--g-orange) 0 14px, transparent 14px 24px);
    opacity: .5;
}

/* Morzsamenü */
.gallery-crumbs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    background: #fff;
    border-radius: 50px;
    padding: 8px 20px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .08);
    font-size: 14px;
}
.gallery-crumbs a { color: var(--g-red); text-decoration: none; font-weight: 600; }
.gallery-crumbs a:hover { color: var(--g-dark-orange); }
.gallery-crumbs span { color: #b9b9b9; }

/* Albumkártyák */
.album-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 28px;
}

.album-card {
    --c: var(--g-orange);
    display: block;
    text-decoration: none;
    color: #4a4a4a;
    background: #fff;
    border-radius: 28px;
    overflow: hidden;
    border-bottom: 8px solid var(--c);
    box-shadow: 0 8px 22px rgba(0, 0, 0, .1);
    transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .3s;
}
.album-card:nth-child(4n+2) { --c: var(--g-green); }
.album-card:nth-child(4n+3) { --c: var(--g-red); }
.album-card:nth-child(4n+4) { --c: var(--g-yellow); }
.album-card:hover {
    transform: translateY(-8px) rotate(-1.2deg);
    box-shadow: 0 18px 34px rgba(0, 0, 0, .18);
    color: #4a4a4a;
}
.album-card:nth-child(even):hover { transform: translateY(-8px) rotate(1.2deg); }

.album-cover {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, var(--g-yellow), var(--g-orange));
}
.album-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s;
}
.album-card:hover .album-cover img { transform: scale(1.08); }
.album-cover .album-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 60px;
    color: rgba(255, 255, 255, .85);
}
.album-count {
    position: absolute;
    top: 14px;
    right: 14px;
    background: var(--c);
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    padding: 6px 14px;
    border-radius: 50px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .25);
}
.album-title {
    font-family: 'Galindo', sans-serif;
    font-size: 18px;
    line-height: 1.3;
    padding: 18px 20px 16px;
    min-height: 82px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* Képrács */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}
.photo-item {
    display: block;
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 22px;
    border: 4px solid #fff;
    box-shadow: 0 6px 16px rgba(0, 0, 0, .12);
    transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .3s;
}
.photo-item:nth-child(5n+1) { border-radius: 30px 14px 30px 14px; }
.photo-item:nth-child(5n+3) { border-radius: 14px 30px 14px 30px; }
.photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s;
}
.photo-item::after {
    content: "\f00e";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    color: #fff;
    background: rgba(229, 106, 63, .45);
    opacity: 0;
    transition: opacity .3s;
}
.photo-item:hover { transform: scale(1.04) rotate(-1deg); box-shadow: 0 14px 28px rgba(0, 0, 0, .2); z-index: 2; }
.photo-item:hover img { transform: scale(1.1); }
.photo-item:hover::after { opacity: 1; }

/* Lapozás */
.gallery-wrap .pagination { gap: 8px; flex-wrap: wrap; }
.gallery-wrap .page-link {
    border: 0;
    border-radius: 50px !important;
    color: var(--g-red);
    background: #fff;
    font-weight: 600;
    padding: 8px 18px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .08);
}
.gallery-wrap .page-link:hover { background: var(--g-yellow); color: #fff; }
.gallery-wrap .page-item.active .page-link { background: var(--g-orange); color: #fff; }
.gallery-wrap .page-item.disabled .page-link { opacity: .5; }

@media (max-width: 575px) {
    .gallery-wrap { border-radius: 28px; padding: 28px 14px 36px; }
    .album-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
    .album-title { font-size: 14px; padding: 12px 10px; min-height: 70px; }
    .photo-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

/* ===== Események / hírek ===== */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 28px;
}

.news-card {
    --c: var(--g-orange);
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 28px;
    overflow: hidden;
    border-bottom: 8px solid var(--c);
    box-shadow: 0 8px 22px rgba(0, 0, 0, .1);
    transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .3s;
}
.news-card:nth-child(4n+2) { --c: var(--g-green); }
.news-card:nth-child(4n+3) { --c: var(--g-red); }
.news-card:nth-child(4n+4) { --c: var(--g-yellow); }
.news-card:hover { transform: translateY(-8px); box-shadow: 0 18px 34px rgba(0, 0, 0, .18); }

/* A kép egésze látszik (plakátoknál is), mögötte elmosott változata tölti ki a keretet */
.news-media {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--g-cream);
    display: block;
}
.news-media::before {
    content: "";
    position: absolute;
    inset: -20px;
    background: var(--bg) center / cover;
    filter: blur(18px) saturate(1.2);
    opacity: .55;
}
.news-media img {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform .5s;
}
.news-card:hover .news-media img { transform: scale(1.05); }

.news-date {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 2;
    background: var(--c);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    padding: 6px 14px;
    border-radius: 50px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .25);
}

.news-body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.news-title {
    font-family: 'Galindo', sans-serif;
    font-size: 19px;
    line-height: 1.3;
    margin: 0 0 10px;
}
.news-title a { color: #4a4a4a; text-decoration: none; }
.news-title a:hover { color: var(--g-red); }
.news-excerpt { font-size: 14px; color: #6b6b6b; margin: 0 0 18px; flex: 1; }

.news-more {
    align-self: flex-start;
    background: var(--c);
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    padding: 9px 20px;
    border-radius: 50px;
    transition: transform .2s, filter .2s;
}
.news-more:hover { color: #fff; transform: translateX(4px); filter: brightness(1.08); }
.news-more i { margin-left: 6px; }

/* Kiemelt (legfrissebb) hír az első oldalon */
.news-card.is-featured { grid-column: 1 / -1; flex-direction: row; }
.news-card.is-featured .news-media { flex: 1.2; aspect-ratio: auto; min-height: 340px; }
.news-card.is-featured .news-body { flex: 1; justify-content: center; padding: 34px; }
.news-card.is-featured .news-title { font-size: 28px; }
.news-card.is-featured .news-excerpt { font-size: 16px; flex: 0 1 auto; }
.news-badge {
    align-self: flex-start;
    background: var(--g-yellow);
    color: #fff;
    font-weight: 700;
    font-size: 12px;
    letter-spacing: .5px;
    text-transform: uppercase;
    padding: 4px 12px;
    border-radius: 50px;
    margin-bottom: 12px;
}

/* Hír részletes oldala */
.article-card {
    background: #fff;
    border-radius: 28px;
    padding: 36px 40px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, .08);
    line-height: 1.7;
    overflow-wrap: anywhere;
}
.article-card img { max-width: 100%; height: auto; border-radius: 18px; }
.article-date {
    display: inline-block;
    background: var(--g-orange);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    padding: 6px 16px;
    border-radius: 50px;
    margin-bottom: 18px;
}
.article-download {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--g-green);
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
    transition: transform .2s;
}
.article-download:hover { color: #fff; transform: translateY(-3px); }

@media (max-width: 767px) {
    .news-card.is-featured { flex-direction: column; }
    .news-card.is-featured .news-media { min-height: 0; aspect-ratio: 16 / 10; }
    .news-card.is-featured .news-body { padding: 22px; }
    .news-card.is-featured .news-title { font-size: 22px; }
    .article-card { padding: 24px 18px; border-radius: 22px; }
}
@media (max-width: 575px) {
    .news-grid { grid-template-columns: 1fr; gap: 20px; }
}
