.news-blocks-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  font-family: 'Playfair Display', 'Open Sans', serif;
}

/* Vezérlők (keresés + szűrők) */
.news-controls {
  margin-bottom: 40px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Keresés */
.news-search {
  position: relative;
  max-width: 400px;
  margin: 0 auto; /* Visszaraktuk a középre igazítást */
  width: 100%; /* Hozzáadtuk a width: 100%-ot a reszponzivitáshoz */
}

.news-search-input {
  width: 100%;
  padding: 16px 50px 16px 20px;
  border: 2px solid #E1E7D0;
  border-radius: 30px;
  font-size: 16px;
  font-family: 'Open Sans', sans-serif;
  background: #FAF4E3;
  color: #2F4644;
  box-sizing: border-box; /* Hozzáadtuk a box-sizing-ot */
}

.news-search-input:focus {
  outline: none;
  border-color: #E1E7D0;
  background: #FAF4E3;
}

.news-search-input::placeholder {
  color: #2F4644;
  opacity: 0.7;
}

.news-search-btn,
.news-search-clear {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #2F4644;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.news-search-btn {
  right: 8px;
}

.news-search-clear {
  right: 38px;
}

.news-search-btn:hover,
.news-search-clear:hover {
  background: rgba(28, 88, 59, 0.1);
  color: #1C583B;
}

/* Szűrők */
.news-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center; /* Középre igazítás */
  padding-bottom: 24px;
  border-bottom: 2px solid #E1E7D0;
}

.filter-btn {
  background: #FAF4E3;
  border: 2px solid #E1E7D0;
  padding: 12px 24px;
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 16px;
  color: #2F4644;
  text-decoration: none;
  display: inline-block;
  font-weight: 600;
  font-family: 'Playfair Display', serif;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  white-space: nowrap; /* Megakadályozza a szöveg törését */
}

.filter-btn:hover {
  background: #1C583B;
  border-color: #1C583B;
  color: #FAF4E3;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(28, 88, 59, 0.2);
}

.filter-btn.active {
  background: #1C583B;
  border-color: #1C583B;
  color: #FAF4E3;
  box-shadow: 0 4px 16px rgba(28, 88, 59, 0.4);
}

/* Grid oszlopok */
.news-grid {
  display: grid;
  gap: 30px;
  margin-bottom: 20px;
}

.news-grid-1 {
  grid-template-columns: 1fr;
}

.news-grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
}

.news-grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

.news-grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.news-item {
  background: #FAF4E3;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(28, 88, 59, 0.1);
  transition: all 0.4s ease;
  border: 1px solid #E1E7D0;
  position: relative;
  cursor: pointer;
}

.news-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #1C583B, #2F4644);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.news-item:hover::before {
  transform: scaleX(1);
}

.news-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(28, 88, 59, 0.2);
  background: #ffffff;
}

.news-image {
  width: 100%;
  height: 240px;
  overflow: hidden;
  position: relative;
}

.news-image::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: linear-gradient(transparent, rgba(28, 88, 59, 0.1));
  pointer-events: none;
}

.news-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  filter: brightness(1.05) contrast(1.1);
}

.news-item:hover .news-image img {
  transform: scale(1.08);
}

.news-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(28, 88, 59, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.news-item:hover .news-overlay {
  opacity: 1;
}

.read-more-indicator {
  color: #FAF4E3;
  font-weight: 600;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.news-content {
  padding: 28px;
}

.news-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  font-size: 14px;
  color: #2F4644;
}

.news-date {
  font-weight: 600;
  color: #1C583B;
  font-family: 'Playfair Display', serif;
  font-size: 15px;
  letter-spacing: 0.5px;
}

.news-category {
  background: linear-gradient(135deg, #1C583B 0%, #2F4644 100%);
  color: #FAF4E3;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-family: 'Open Sans', sans-serif;
  box-shadow: 0 2px 8px rgba(28, 88, 59, 0.3);
}

.news-title {
  margin: 0 0 16px 0;
  font-size: 24px;
  line-height: 1.3;
  font-weight: 500;
  font-family: 'Playfair Display', serif;
  color: #2F4644;
}

.news-excerpt {
  color: #2F4644;
  font-size: 16px;
  line-height: 1.6;
  margin: 0 0 16px 0;
  font-family: 'Open Sans', sans-serif;
  opacity: 0.9;
}

.news-read-more {
  opacity: 0;
  transition: opacity 0.3s ease;
}

.news-item:hover .news-read-more {
  opacity: 1;
}

.read-more-text {
  color: #1C583B;
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Lapozás */
.news-pagination {
  margin-top: 40px;
  padding-top: 30px;
  border-top: 2px solid #E1E7D0;
  display: flex;
  justify-content: center;
}

.pagination-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

.pagination-btn {
  min-width: 44px;
  height: 44px;
  border: 2px solid #E1E7D0;
  background: #FAF4E3;
  color: #2F4644;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 16px;
  font-weight: 600;
  font-family: 'Playfair Display', serif;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.pagination-btn:hover {
  border-color: #1C583B;
  background: #1C583B;
  color: #FAF4E3;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(28, 88, 59, 0.2);
}

.pagination-btn.active {
  background: #1C583B;
  border-color: #1C583B;
  color: #FAF4E3;
  box-shadow: 0 4px 16px rgba(28, 88, 59, 0.4);
}

.pagination-prev,
.pagination-next {
  padding: 0 12px;
}

.pagination-dots {
  color: #2F4644;
  font-weight: 600;
  padding: 0 8px;
}

.news-no-posts {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 20px;
  color: #2F4644;
  font-size: 18px;
  background: #FAF4E3;
  border-radius: 16px;
  border: 2px dashed #E1E7D0;
  font-family: 'Playfair Display', serif;
  font-weight: 500;
}

.loading-spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 60px;
  color: #2F4644;
  font-size: 18px;
  font-family: 'Playfair Display', serif;
  font-weight: 500;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 4px solid #E1E7D0;
  border-top: 4px solid #1C583B;
  border-radius: 50%;
  animation: spin 1.2s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Animációk */
.news-item {
  animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Reszponzív design */
@media (max-width: 1024px) {
  .news-blocks-container {
    padding: 20px 15px;
  }
  
  .news-grid-2,
  .news-grid-3,
  .news-grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
  }
}

@media (max-width: 768px) {
  .news-blocks-container {
    padding: 15px;
  }

  .news-grid-2,
  .news-grid-3,
  .news-grid-4 {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .news-controls {
    gap: 15px;
    margin-bottom: 30px;
  }

  .news-search {
    max-width: 100%;
    margin: 0; /* Mobilon ne legyen auto margin */
  }

  .news-search-input {
    padding: 14px 45px 14px 18px;
    font-size: 15px;
  }

  .news-filter {
    justify-content: center;
    gap: 8px;
  }

  .filter-btn {
    font-size: 14px;
    padding: 10px 16px;
    min-width: fit-content;
  }

  .news-content {
    padding: 24px;
  }

  .news-title {
    font-size: 20px;
  }

  .news-image {
    height: 200px;
  }

  .news-excerpt {
    font-size: 15px;
  }

  .pagination-btn {
    min-width: 38px;
    height: 38px;
    font-size: 14px;
  }

  .pagination-wrapper {
    gap: 6px;
  }
}

@media (max-width: 480px) {
  .news-blocks-container {
    padding: 10px;
  }

  .news-search {
    width: 100%;
    max-width: 100%;
  }

  .news-search-input {
    padding: 12px 40px 12px 16px;
    font-size: 14px;
  }

  .news-search-btn {
    right: 6px;
    padding: 6px;
  }

  .news-search-clear {
    right: 32px;
    padding: 6px;
  }

  .news-filter {
    gap: 6px;
  }

  .filter-btn {
    font-size: 12px;
    padding: 8px 14px;
    letter-spacing: 0.3px;
  }

  .news-image {
    height: 180px;
  }

  .news-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .news-content {
    padding: 20px;
  }

  .news-title {
    font-size: 18px;
  }

  .news-excerpt {
    font-size: 14px;
  }

  .pagination-btn {
    min-width: 34px;
    height: 34px;
    font-size: 13px;
  }

  .pagination-wrapper {
    gap: 4px;
  }
}

/* Extra kis képernyők */
@media (max-width: 360px) {
  .news-blocks-container {
    padding: 8px;
  }

  .news-search-input {
    padding: 10px 35px 10px 14px;
    font-size: 13px;
  }

  .filter-btn {
    font-size: 11px;
    padding: 6px 12px;
  }

  .news-content {
    padding: 16px;
  }

  .pagination-btn {
    min-width: 30px;
    height: 30px;
    font-size: 12px;
  }
}

/* Focus állapotok akadálymentesítéshez */
.filter-btn:focus,
.pagination-btn:focus,
.news-search-btn:focus,
.news-search-clear:focus {
  outline: 3px solid #1C583B;
  outline-offset: 2px;
}

.news-search-input:focus {
  outline: 3px solid #1C583B;
  outline-offset: 2px;
}

.news-item:focus {
  outline: 3px solid #1C583B;
  outline-offset: 2px;
}