/* Modernizált Aktualitások szekció - Apple-stílusú design nagyméretű kártyákkal */
.newsfeed-section {
  display: flex;
  align-content: center;
  align-items: center;
  flex-direction: column;
  font-family: var(--regular-text);
  width: 100%;
  background-color: var(--white-orange);
  padding-left: 1rem;
  padding-right: 1rem;
  padding-top: 5rem;
  padding-bottom: 5rem;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

/* Közvetlenül a hero után kisebb felső térköz, hogy a címsor
   már az oldal tetején állva is kilátszódjon a hero alól */
.hero + .newsfeed-section {
  padding-top: 2.5rem;
  --accent: var(--primary-light);
}

/* Háttér réteg */
.newsfeed-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--white-orange);
  z-index: -1;
}

/* Interaktív háttér elem */
.newsfeed-section .background-glow {
  position: absolute;
  top: 10%;
  left: 50%;
  transform: translateX(-50%);
  width: 40%;
  height: 50px;
  background: rgba(173, 255, 47, 0.15);
  filter: blur(100px);
  opacity: 0.3;
  z-index: -1;
  border-radius: 50%;
  animation: subtle-glow 8s ease-in-out infinite alternate;
}

@keyframes subtle-glow {
  0% {
    opacity: 0.2;
    width: 30%;
    filter: blur(80px);
  }
  100% {
    opacity: 0.3;
    width: 50%;
    filter: blur(100px);
  }
}

/* Szekció címsor */
.newsfeed-section .section-title {
  font-family: var(--regular-text);
  font-weight: 600;
  font-size: 2.5rem;
  color: #333;
  margin-bottom: 2rem;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  position: relative;
}

/* Dock szűrősáv a tetején */
.news-filter-dock {
  display: flex;
  width: 100%;
  justify-content: center;
  align-items: center;
  min-width: 80%;
  max-width: 700px;
  margin-bottom: 3rem;

  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 18px;
  padding: 0.8rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(0, 0, 0, 0.04);
  gap: 1rem;
  flex-wrap: wrap;
  z-index: 10; /* Biztosítjuk, hogy a szűrősáv a kártyák felett legyen */
}

.filter-group {
  display: flex;
  align-items: center;
  position: relative;
}

.filter-group:not(:last-child)::after {
  content: "";
  position: absolute;
  right: -0.5rem;
  height: 60%;
  width: 1px;
  background-color: rgba(0, 0, 0, 0.1);
}

.filter-label {
  font-size: 0.85rem;
  color: #555;
  margin-right: 0.4rem;
  font-weight: 500;
}

.filter-option {
  background: transparent;
  border: none;
  padding: 0.45rem 0.6rem;
  border-radius: 15px;
  font-size: 0.85rem;
  color: #333;
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-option:hover,
.filter-option.active {
  background-color: rgba(0, 0, 0, 0.04);
}

.filter-option.active {
  font-weight: 600;
  color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.tag-filter .filter-option {
  
  margin: 0 0.2rem;
}

.tag-filter .filter-option[data-tag="akcio"].active {
  background-color: rgba(229, 57, 53, 0.1);
  color: #c62828;
}

.tag-filter .filter-option[data-tag="hir"].active {
  background-color: rgba(255, 152, 0, 0.1);
  color: #ef6c00;
}

.tag-filter .filter-option[data-tag="esemeny"].active {
  background-color: rgba(33, 150, 243, 0.1);
  color: #1565c0;
}

.tag-filter .filter-option[data-tag="allas"].active {
  background-color: rgba(117, 184, 41, 0.1);
  color: #558b2f;
}

/* Konténer a kártyáknak */
.news-feed-container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  justify-content: center;
}

/* Grid elrendezés nagyméretű kártyákhoz */
.news-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  width: 100%;
  justify-items: center;
  margin: 0 auto;
}

/* Nagyméretű, világos színű kártyák */
.news-card {
  position: relative;
  height: auto;
  overflow: hidden;
  border-radius: 18px;
  background-color: #ffffff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06), 0 6px 20px rgba(0, 0, 0, 0.05);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  border: 0;
  transform-origin: center;
  width: 100%;
  max-width: 700px;
  padding-bottom: 60px;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform, opacity;
  font-size: 0; /* Eltávolítja az inline elemek közötti térközt a kártyán belül */
}

.news-card.show {
  opacity: 1;
  transform: translateY(0);
}

/* Felső információs sáv */
.news-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.15rem 1.5rem;
  background-color: #ffffff;
  border-bottom: 1px solid #f0f0f0;
  z-index: 3;
}

/* Dátum megjelenítése a felső sávban */
.news-date {
  display: flex;
  align-items: baseline;
  color: #333;
  line-height: 1.2;
}

.news-date .day {
  font-size: 1.4rem;
  font-weight: 700;
  color: #222;
  margin-right: 0.4rem;
}

.news-date .year-month-day {
  font-size: 0.98rem;
  color: #444;
  font-weight: 600;
}

/* Kategória címkék - hasonló stílussal, mint a stocked-available címkék */
.news-tag {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 25px;
  min-width: 86px;
  padding: 0.35rem 0rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--accent);
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  border: 1px solid var(--accent);
  background: transparent;
}

/* Egységes akcentus alapú címkék (var(--primary-light)) */
.news-tag.tag-akcio,
.news-tag.tag-allas,
.news-tag.tag-esemeny,
.news-tag.tag-hir {
  background: transparent;
  border: 1px solid var(--accent);
  color: var(--accent);
}

/* A képkonténer tartalmazza a fő képet */
.news-image-container {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 40%;
  overflow: hidden;
  margin-bottom: 0;
  line-height: 0;
  font-size: 0;
  display: block;
  background-color: #f0f0f0; /* Placeholder háttérszín */
  background-image: linear-gradient(
    90deg,
    #f0f0f0 0%,
    #e0e0e0 50%,
    #f0f0f0 100%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.news-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.3s ease-in-out;
  opacity: 0;
  will-change: transform, opacity;
  display: block;
  margin: 0;
  padding: 0;
  border: 0;
}

.news-image.loaded {
  opacity: 1;
}

.news-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 0 0 2px var(--accent), 0 14px 35px rgba(0, 0, 0, 0.10);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Alsó homályos sáv a részletek gombbal */
.news-card-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 0.9rem 1.2rem;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  justify-content: flex-end;
  align-items: center;
  z-index: 2;
  height: auto;
  margin-top: 0; /* Biztosítom, hogy nincs margó a tetején */
  border-top: 1px solid rgba(0, 0, 0, 0.06); /* Finom felső elválasztó */
}

/* Részletek gomb az alsó sávban */
.news-more-btn {
  font-size: 1.2rem;
  font-weight: 600;
  font-family: var(--regular-text);
  color: white;
  background: #252525;
  border: none;
  border-radius: 12px;
  padding: 0.6rem 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
  text-shadow: none;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
  letter-spacing: 0.3px;
}

.news-more-btn:hover {
  transform: translateX(4px);
  text-shadow: none;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.20);
}

/* Eltávolítjuk a régi nyíl stílusokat */
.news-more-btn .arrow {
  display: none;
}

/* Animációk a kártyák fokozatos megjelenéséhez */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.news-card {
  animation: none;
  animation-delay: 0s;
}

/* 2 oszlopos elrendezéshez módosított megjelenési animáció */
@media (min-width: 1200px) {
  .news-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 3.5rem;
    max-width: 1400px;
  }

  .news-card {
    width: 100%;
    max-width: 700px; /* Növeljük a maximális szélességet */
    overflow: hidden;
  }

  .news-image-container {
    padding-bottom: 50%; /* Növeljük a magasságot */
    line-height: 0; /* Biztosítjuk minden képernyőméretnél */
    font-size: 0;
    margin: 0;
    padding-bottom: 50%;
  }

  .news-image {
    margin: 0;
    padding: 0;
    border: 0;
    display: block;
  }

  .news-card-bottom {
    height: 70px; /* Magasabb alsó sáv */
    padding: 1rem 1.5rem;
    margin-top: 0;
    border-top: none;
  }

  /* Egy kártya esetén középre igazítás */
  .news-card.single-card {
    grid-column: 1 / span 2;
    max-width: 850px;
  }

  .news-card-top {
    padding: 1.35rem 2rem; /* Nagyobb padding */
  }

  .news-date .day {
    font-size: 1.6rem; /* Nagyobb dátum */
  }

  .news-date .year-month-day {
    font-size: 1.1rem;
  }

  .news-tag {
    height: 28px;
    width: 100px;
    font-size: 0.85rem;
  }

  .news-more-btn {
    font-size: 1.1rem;
    padding: 0.6rem 1.3rem;
  }
}

@media (min-width: 992px) and (max-width: 1199px) {
  .news-grid {
    gap: 3.5rem;
  }

  .news-card {
    width: 100%;
    max-width: 850px;
  }

  .news-image-container {
    line-height: 0;
    font-size: 0;
    margin: 0;
  }

  .news-image {
    margin: 0;
    padding: 0;
    border: 0;
    display: block;
  }

  .news-card-bottom {
    margin-top: 0;
    border-top: none;
  }
}

@media (max-width: 991px) {
  .news-filter-dock {

    padding: 0.6rem;
    flex-direction: column;
    gap: 0.8rem;
  }

  .filter-group {
    width: 100%;
    justify-content: center;
  }

  .filter-group:not(:last-child)::after {
    display: none;
  }

  .news-card-top {
    padding: 1.2rem;
  }

  .news-card-bottom {
    padding: 1.2rem;
  }

  .news-more-btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
    background: var(--accent);
    color: #ffffff;
    font-weight: 600;
  }

  .news-image-container {
    line-height: 0;
    font-size: 0;
    margin: 0;
  }

  .news-image {
    margin: 0;
    padding: 0;
    border: 0;
    display: block;
  }

  .news-card-bottom {
    margin-top: 0;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
  }
}

@media (max-width: 767px) {
  .newsfeed-section {
    padding: 3.5rem 0;
  }

  .news-image-container {
    padding-bottom: 45%; /* Mobilon magasabb arány */
    line-height: 0; /* Biztosítjuk minden képernyőméretnél */
    font-size: 0;
    margin: 0;
  }

  .news-grid {
    gap: 2.5rem;
  }

  .news-card {
    max-width: 100%; /* Mobilon teljes szélesség */
    padding-bottom: 55px; /* Kissé kisebb alsó padding mobilon */
    overflow: hidden;
  }

  .newsfeed-section .section-title {
    font-size: 2rem;
    margin-bottom: 1.5rem;
  }

  .news-filter-dock {

  }

  .news-card-bottom {
    height: 55px; /* Kisebb magasság mobilon */
    margin-top: 0;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
  }

  .news-image {
    margin: 0;
    padding: 0;
    border: 0;
    display: block;
  }

  .news-card-bottom {
    margin-top: 0;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
  }
}

@media (max-width: 576px) {
  .newsfeed-section {
    padding: 3rem 0;
  }

  .newsfeed-section .section-title {
    font-size: 1.8rem;
  }

  .filter-option {
    font-size: 0.7rem;
  }

  .news-grid {
    gap: 2rem;
  }

  .news-date .day {
    font-size: 1.2rem;
  }

  .news-date .year-month-day {
    font-size: 0.85rem;
  }

  .news-tag {
    height: 22px;
    width: 80px;
    font-size: 0.75rem;
  }

  .news-more-btn {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    background: var(--accent);
    color: #ffffff;
    font-weight: 600;
  }

  .news-card {
    padding-bottom: 50px; /* Még kisebb alsó padding kisebb mobilokon */
  }

  .news-image-container {
    line-height: 0;
    font-size: 0;
    margin: 0;
  }

  .news-image {
    margin: 0;
    padding: 0;
    border: 0;
    display: block;
  }

  .news-card-bottom {
    height: 50px; /* Kisebb magasság kisebb mobilokon */
    padding: 0.6rem 1rem; /* Kisebb padding a gombnak */
    margin-top: 0;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
  }
}

/* Fokuszálási állapot a hozzáférhetőség miatt */
.news-card:focus {
  outline: 3px solid rgba(255, 213, 108, 0.6);
}

/* Elrejtett elemek */
.news-title,
.news-description,
.news-card-content {
  display: none;
}

/* Reset gomb stílusok */
.reset-filters {
  display: flex;
  align-items: center;
}

.reset-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(0, 0, 0, 0.05);
  color: #666;
  transition: all 0.3s ease;
}

.reset-btn:hover {
  background-color: rgba(0, 0, 0, 0.1);
  color: #333;
}

.reset-btn .reset-icon {
  font-size: 1.1rem;
  transition: transform 0.3s ease;
}

.reset-btn:hover .reset-icon {
  transform: rotate(-180deg);
}

/* Reszponzív módosítások a reset gombhoz */
@media (max-width: 991px) {
  .reset-filters {
    width: 100%;
    justify-content: center;
  }

  .reset-btn {
    padding: 0.6rem 1.2rem;
  }
}

/* Modal ablak stílusok */
.news-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.news-modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.news-modal {
  background-color: #ffffff;
  border-radius: 24px;
  width: 95%;
  max-width: 1150px;
  max-height: 88vh;
  overflow: hidden;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.14);
  display: flex;
  flex-direction: column;
  transform: scale(0.94);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid rgba(0, 0, 0, 0.06);
  position: relative;
}

.news-modal-overlay.active .news-modal {
  transform: scale(1);
  opacity: 1;
}

.news-modal-top {
  padding: 1.25rem 2rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.news-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.news-modal-date-tag {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.news-modal-title {
  font-family: var(--regular-text);
  font-weight: 600;
  font-size: 2rem;
  color: #222;
  margin: 0;
  line-height: 1.25;
  letter-spacing: 0.01em;
}

/* Modal címke (tag) – erősebb, akcentusos megjelenés */
.news-modal-date-tag .news-tag,
#modal-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  padding: 0 0.75rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  background: var(--primary-light);
  color: #ffffff;
  border: 1px solid transparent;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.news-modal-close {
  background: rgba(0, 0, 0, 0.05);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  color: #555;
  cursor: pointer;
  transition: all 0.2s ease;
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
}

.news-modal-close:hover {
  background: rgba(0, 0, 0, 0.08);
  transform: rotate(90deg);
  box-shadow: 0 0 0 2px var(--primary-light);
}

.news-modal-content {
  flex: 1;
  overflow: hidden;
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 0;
  max-height: calc(88vh - 120px);
}

.news-modal-image-container {
  width: 100%;
  height: 100%;
  min-height: 40vh;
  position: relative;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  background: linear-gradient(180deg, #fafafa 0%, #f3f3f3 100%);
  border-right: 1px solid rgba(0, 0, 0, 0.05);
}

.news-modal-image {
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: calc(88vh - 140px);
  object-fit: contain;
  transition: transform 0.2s ease;
}

.news-modal-image:hover {
  transform: scale(1.01);
}

.news-modal-text {
  padding: 2rem;
  overflow-y: auto;
  height: 100%;
  max-height: calc(88vh - 120px);
  max-width: 72ch;
  margin: 0 auto;
  font-family: var(--regular-text);
  font-size: 1.06rem;
  line-height: 1.75;
  color: #333;
}

.news-modal-text p {
  margin: 0 0 1rem 0;
  line-height: 1.8;
  font-family: var(--regular-text);
}

/* A modal szövegterületén belül minden elem egységes betűtípust kap */
.news-modal-text * {
  font-family: var(--regular-text);
}

/* Tipográfia: címek, bekezdések, listák, idézetek, linkek */
.news-modal-text h1,
.news-modal-text h2,
.news-modal-text h3,
.news-modal-text h4,
.news-modal-text h5,
.news-modal-text h6 {
  font-weight: 600;
  color: #222;
  line-height: 1.25;
  margin: 1.2rem 0 0.6rem 0;
}

.news-modal-text h1 { font-size: 1.6rem; }
.news-modal-text h2 { font-size: 1.4rem; }
.news-modal-text h3 { font-size: 1.25rem; }
.news-modal-text h4 { font-size: 1.15rem; }
.news-modal-text h5 { font-size: 1.05rem; }
.news-modal-text h6 { font-size: 0.95rem; letter-spacing: 0.02em; }

.news-modal-text ul,
.news-modal-text ol {
  margin: 0 0 1rem 0;
  padding-left: 1.25rem;
}
.news-modal-text ul { list-style: disc; }
.news-modal-text ol { list-style: decimal; }
.news-modal-text li { margin: 0.25rem 0; line-height: 1.7; }
.news-modal-text ul li::marker,
.news-modal-text ol li::marker { color: var(--primary-light); }

.news-modal-text a {
  color: var(--primary-light);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}
.news-modal-text a:hover { text-decoration-thickness: 2px; }

.news-modal-text strong { font-weight: 700; }
.news-modal-text em { font-style: italic; }

.news-modal-text blockquote {
  margin: 1.2rem 0;
  padding: 0.75rem 1rem;
  border-left: 4px solid var(--primary-light);
  background: rgba(0, 0, 0, 0.02);
  color: #444;
  border-radius: 8px;
}

/* Finomított bekezdés ritmus */
.news-modal-text p:first-of-type {
  font-size: 1.1rem;
  color: #2e2e2e;
}

/* Vízszintes vonal, kódrészletek, small szöveg */
.news-modal-text hr {
  height: 1px;
  border: none;
  background: rgba(0, 0, 0, 0.08);
  margin: 1.25rem 0;
}

.news-modal-text small {
  font-size: 0.875rem;
  color: #666;
}

.news-modal-text code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  background: rgba(0, 0, 0, 0.04);
  padding: 0.1rem 0.35rem;
  border-radius: 6px;
  font-size: 0.95em;
}

.news-modal-text pre {
  background: rgba(0, 0, 0, 0.04);
  padding: 1rem;
  border-radius: 10px;
  overflow: auto;
}
.news-modal-text pre code {
  background: transparent;
  padding: 0;
}

/* Mobil tipográfia finomhangolás */
@media (max-width: 768px) {
  .news-modal-text h1 { font-size: 1.4rem; }
  .news-modal-text h2 { font-size: 1.3rem; }
  .news-modal-text h3 { font-size: 1.2rem; }
}

/* Képek a modal szövegében */
.news-modal-text img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1rem auto;
  border-radius: 12px;
}

/* Jobb tördelés hosszú szövegeknél */
.news-modal-text {
  letter-spacing: 0.01em;
  word-break: normal;
  overflow-wrap: anywhere;
  hyphens: auto;
}

/* Responsive modal design */
@media (max-width: 768px) {
  .news-modal {
    width: 96%;
    max-height: 92vh;
    border-radius: 20px;
  }

  .news-modal-top {
    padding: 1rem 1.25rem;
  }

  .news-modal-title {
    font-size: 1.6rem;
  }

  .news-modal-content {
    display: block;
    max-height: calc(92vh - 110px);
  }

  .news-modal-image-container {
    height: auto;
    max-height: 60vh;
    border-right: none;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  }

  .news-modal-image {
    max-height: 60vh;
  }

  .news-modal-text {
    padding: 1.25rem 1.25rem 1.5rem 1.25rem;
    font-size: 1rem;
    max-height: calc(92vh - 110px - 60vh);
  }

  .news-modal-content {
    max-height: calc(92vh - 110px);
  }
}

@media (max-width: 400px) {

  .filter-label {
    font-size: 0.75rem;
  }
  .filter-option {
    font-size: 0.65rem;
    padding: 0.4rem 0.5rem;
  }
}

/* Modal megjelenése és eltűnése */
@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

.news-modal.animate-in {
  animation: modalFadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.news-modal.animate-out {
  animation: modalFadeOut 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* "Mégtöbb" – a 4 legfrissebb hír után további kártyák */
.news-card.news-card--collapsed {
  display: none;
}

.news-load-more-wrap {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-top: 2.5rem;
}

.news-load-more-wrap[hidden] {
  display: none;
}

.news-load-more-btn {
  font-family: var(--regular-text);
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  color: #252525;
  background: transparent;
  border: 1.5px solid #252525;
  border-radius: 999px;
  padding: 0.75rem 2.4rem;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.news-load-more-btn:hover {
  background: #252525;
  color: #ffffff;
}

.news-load-more-btn:active {
  transform: scale(0.97);
}

.news-load-more-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ==========================================================
   Szűrő dock – lenyíló menük (közös: asztali + mobil)
   ========================================================== */
.category-dropdown {
  display: none; /* csak mobil/tablet nézetben látszik */
}

.sort-dropdown {
  position: relative;
  display: flex;
}

.dock-chevron {
  flex: 0 0 auto;
  color: #888;
  transition: transform 0.2s ease;
}

.is-open > button .dock-chevron {
  transform: rotate(180deg);
}

/* Színes pötty a kategóriákhoz (a kártya címkék színeivel egyezik) */
.category-dot {
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}
.category-dot[data-tag="akcio"] { background: #e53935; }
.category-dot[data-tag="hir"] { background: #ef6c00; }
.category-dot[data-tag="esemeny"] { background: #1e88e5; }
.category-dot[data-tag="allas"] { background: #75b829; }

.dock-menu {
  position: absolute;
  top: calc(100% + 0.6rem);
  left: 0;
  min-width: 100%;
  margin: 0;
  padding: 0.35rem;
  list-style: none;
  background: #fff;
  border-radius: 16px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14);
  transform-origin: top left;
  animation: dockMenuIn 0.16s ease-out;
  z-index: 30;
}

/* A rendezés menü a dock jobb széléhez igazodik, hogy ne lógjon ki */
.sort-menu {
  left: auto;
  right: 0;
  min-width: 190px;
  transform-origin: top right;
}

.dock-menu[hidden] {
  display: none;
}

.dock-menu-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  width: 100%;
  min-height: 44px;
  padding: 0.6rem 0.8rem;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: #333;
  font-size: 0.95rem;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.dock-menu-item:hover,
.dock-menu-item:active,
.dock-menu-item:focus-visible {
  background-color: rgba(0, 0, 0, 0.05);
  outline: none;
}

.dock-menu-item[aria-selected="true"] {
  font-weight: 700;
  color: #1d1d1f;
}

.sort-menu-icon {
  flex: 0 0 auto;
  color: #888;
}

.sort-menu-icon.is-oldest {
  transform: scaleY(-1);
}

.dock-menu-item[aria-selected="true"] .sort-menu-icon {
  color: var(--accent);
}

.dock-menu-check {
  flex: 0 0 auto;
  margin-left: auto;
  padding-left: 0.5rem;
  box-sizing: content-box;
  color: var(--accent);
  visibility: hidden;
}

.dock-menu-item[aria-selected="true"] .dock-menu-check {
  visibility: visible;
}

/* ==========================================================
   Szűrő dock – kompakt, egysoros mobil + tablet nézet
   [ ● Kategória: Összes  ▾ | ⇅ Legújabb ]
   ========================================================== */
@media (max-width: 1024px) {
  .news-feed-container:has(> .news-filter-dock) {
    padding: 0 1rem;
  }

  .news-filter-dock {
    position: relative;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-width: 0;
    max-width: 520px; /* tableten ne nyúljon túl szélesre */
    gap: 0;
    padding: 0.3rem;
    margin-bottom: 1.75rem;
    border-radius: 999px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.06);
    z-index: 20;
  }

  /* Felesleges elemek elrejtése: címkék, chipek, külön rendezés gombok, törlés */
  .news-filter-dock .filter-group {
    display: none;
  }

  /* --- Kategória lenyíló --- */
  .category-dropdown {
    display: block;
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
  }

  .category-trigger {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    width: 100%;
    min-height: 40px;
    padding: 0.5rem 0.9rem;
    border: none;
    border-radius: 999px;
    background: transparent;
    color: #333;
    font-size: 0.88rem;
    line-height: 1;
    text-align: left;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background-color 0.15s ease;
  }

  .category-trigger:active,
  .category-dropdown.is-open .category-trigger {
    background-color: rgba(0, 0, 0, 0.04);
  }

  .category-trigger-label {
    color: #777;
    font-weight: 500;
  }

  .category-trigger-value {
    font-weight: 700;
    color: #222;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .category-chevron {
    margin-left: auto;
    flex: 0 0 auto;
    color: #888;
    transition: transform 0.2s ease;
  }

  .category-dropdown.is-open .category-chevron {
    transform: rotate(180deg);
  }

  /* --- Rendezés lenyíló: kompakt gomb a dock jobb szélén --- */
  .sort-dropdown {
    flex: 0 0 auto;
  }

  .sort-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    flex: 0 0 auto;
    min-height: 40px;
    padding: 0.5rem 0.85rem;
    margin-left: 0.3rem;
    border: none;
    border-left: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 0 999px 999px 0;
    background: transparent;
    color: #333;
    font-size: 0.82rem;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }

  .sort-toggle:active,
  .sort-dropdown.is-open .sort-toggle {
    background-color: rgba(0, 0, 0, 0.04);
  }

  .sort-toggle:focus-visible,
  .category-trigger:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 1px;
  }

  .sort-toggle-icon {
    color: var(--accent);
    transition: transform 0.25s ease;
  }

  .sort-toggle.is-oldest .sort-toggle-icon {
    transform: scaleY(-1);
  }
}

@media (max-width: 380px) {
  /* Nagyon keskeny kijelzőn: "Kategória:" felirat és rendezés szöveg elrejtése */
  .category-trigger-label,
  .sort-toggle-text {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }

  .sort-toggle {
    padding: 0.5rem 0.75rem;
  }
}

@keyframes dockMenuIn {
  from {
    opacity: 0;
    transform: translateY(-4px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .dock-menu {
    animation: none;
  }
}

/* ==========================================================
   Szűrő dock – asztali nézet (macOS-ihletésű szegmentált vezérlő)
   [ (● Összes) ● Akció  ● Hír  ● Esemény  ● Állás  |  ⇅ Legújabb ]
   Színek: semleges szürkék, az akcentszín csak ikonon/fókuszon,
   a kategóriák színét csak kis pötty jelzi (mint mobilon).
   ========================================================== */
@media (min-width: 1025px) {
  .news-filter-dock {
    position: relative;
    z-index: 20; /* a lenyíló menü a kártyák fölé kerüljön */
    display: inline-flex;
    flex-wrap: nowrap;
    width: auto;
    min-width: 0;
    max-width: none;
    gap: 0.35rem;
    padding: 0.35rem;
    margin-bottom: 2.75rem;
    border-radius: 999px;
    background-color: rgba(255, 255, 255, 0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 10px 30px rgba(0, 0, 0, 0.06);
  }

  /* Felesleges elemek: címkék, külön rendezés gombok, törlés gomb */
  .news-filter-dock .filter-label,
  .news-filter-dock .date-sort,
  .news-filter-dock .reset-filters {
    display: none;
  }

  .news-filter-dock .filter-group::after {
    display: none;
  }

  /* Szegmentált sáv */
  .news-filter-dock .tag-filter {
    position: relative;
    isolation: isolate;
    gap: 2px;
    padding: 3px;
    border-radius: 999px;
    background-color: transparent; /* fehér sáv: a dock fehér háttere látszik */
  }

  .news-filter-dock .tag-filter .filter-option {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0.5rem 1.05rem;
    border-radius: 999px;
    background: transparent;
    box-shadow: none;
    color: #6e6e73;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.01em;
    transition: color 0.2s ease;
  }

  .news-filter-dock .tag-filter .filter-option:hover {
    background: transparent;
    color: #1d1d1f;
  }

  /* Aktív állapot: semleges, sötét szöveg – a színes háttereket kivezetjük */
  .news-filter-dock .tag-filter .filter-option[data-tag].active {
    background: transparent;
    box-shadow: none;
    color: #1d1d1f;
    font-weight: 600;
  }

  /* JS nélküli tartalék: fehér kijelölés közvetlenül a gombon */
  .news-filter-dock .tag-filter:not(.has-thumb) .filter-option[data-tag].active {
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.06);
  }

  /* Kategória pöttyök (ugyanazok a színek, mint a mobil lenyíló menüben) */
  .news-filter-dock .tag-filter .filter-option::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    opacity: 0.45;
    transition: opacity 0.2s ease, transform 0.2s ease;
  }
  .news-filter-dock .tag-filter .filter-option[data-tag="all"]::before { display: none; }
  .news-filter-dock .tag-filter .filter-option[data-tag="akcio"]::before { background: #e53935; }
  .news-filter-dock .tag-filter .filter-option[data-tag="hir"]::before { background: #ef6c00; }
  .news-filter-dock .tag-filter .filter-option[data-tag="esemeny"]::before { background: #1e88e5; }
  .news-filter-dock .tag-filter .filter-option[data-tag="allas"]::before { background: #75b829; }

  .news-filter-dock .tag-filter .filter-option:hover::before,
  .news-filter-dock .tag-filter .filter-option.active::before {
    opacity: 1;
  }

  /* Csúszó fehér kijelölő */
  .segment-thumb {
    position: absolute;
    top: 3px;
    bottom: 3px;
    left: 0;
    z-index: 0;
    width: 0;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.06); /* fehér háttéren is kivehető */
    transition: transform 0.32s cubic-bezier(0.3, 0.7, 0.2, 1),
      width 0.32s cubic-bezier(0.3, 0.7, 0.2, 1);
    pointer-events: none;
  }

  .thumb-no-anim .segment-thumb {
    transition: none;
  }

  /* Rendezés-váltó – ugyanaz a gomb, mint mobilon */
  .sort-toggle {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    flex: 0 0 auto;
    min-height: 38px;
    padding: 0.5rem 1.05rem 0.5rem 0.95rem;
    margin-left: 0.6rem;
    border: none;
    border-radius: 999px;
    background: transparent;
    color: #1d1d1f;
    font-size: 0.9rem;
    font-weight: 500;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 0.2s ease;
  }

  /* Halk elválasztó a szegmentált sáv és a rendezés között */
  .sort-toggle::before {
    content: "";
    position: absolute;
    left: -0.5rem;
    top: 50%;
    width: 1px;
    height: 18px;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.1);
  }

  .sort-toggle:hover,
  .sort-dropdown.is-open .sort-toggle {
    background-color: rgba(0, 0, 0, 0.045);
  }

  .sort-toggle:active {
    background-color: rgba(0, 0, 0, 0.07);
  }

  .sort-toggle-icon {
    color: var(--accent);
    transition: transform 0.25s ease;
  }

  .sort-toggle.is-oldest .sort-toggle-icon {
    transform: scaleY(-1);
  }

  .news-filter-dock .tag-filter .filter-option:focus-visible,
  .sort-toggle:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
  }
}

@media (min-width: 1025px) and (prefers-reduced-motion: reduce) {
  .segment-thumb,
  .sort-toggle-icon {
    transition: none;
  }
}

/* ==========================================================
   Üres állapot – nincs megjeleníthető hír
   Egy hírkártyányi helyet tart fenn (fejléc + kép arány + alsó sáv),
   így a szekció magassága szűréskor sem esik össze.
   ========================================================== */
.news-empty {
  display: grid;
  width: 100%;
  max-width: 700px;
  background: none; /* háttérmentes, nem kártya */
  animation: newsEmptyIn 0.35s ease-out;
}

.news-empty[hidden] {
  display: none;
}

/* A méretező és a tartalom ugyanabban a rácscellában, egymáson */
.news-empty-sizer,
.news-empty-content {
  grid-area: 1 / 1;
}

/* Kártya magasság utánzása: fejléc (~62px) + kép (szélesség %-a) + alsó sáv (60px) */
.news-empty-sizer {
  display: block;
  height: 0;
  padding-bottom: calc(40% + 122px);
}

.news-empty-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  padding: 2rem 1.5rem;
  text-align: center;
}

.news-empty-icon {
  color: var(--accent);
  opacity: 0.85;
  width: 52px;
  height: 52px;
}

.news-empty-text {
  margin: 0;
  max-width: 22ch;
  font-family: var(--regular-text);
  font-size: clamp(1.4rem, 1.1rem + 1.2vw, 1.9rem);
  font-weight: 500;
  line-height: 1.35;
  color: #3a3a3c;
}

@media (min-width: 1200px) {
  .news-empty {
    grid-column: 1 / -1; /* 2 oszlopos rácsban középen, egy kártya szélességben */
    justify-self: center;
  }

  .news-empty-sizer {
    padding-bottom: calc(50% + 130px);
  }
}

@media (max-width: 767px) {
  .news-empty-sizer {
    padding-bottom: calc(45% + 115px);
  }


}

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

@media (prefers-reduced-motion: reduce) {
  .news-empty {
    animation: none;
  }
}
