.home-news {
  padding-top: 10px;
  scroll-margin-top: 110px;
}

.home-news .section-title {
  margin-bottom: 20px;
}

.home-news-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.home-news-card,
.home-news-empty {
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: 22px;
  background: var(--panel);
}

.home-news-card.is-pinned {
  border-color: var(--accent);
  background: linear-gradient(145deg, #fffaf5, #f5e9dc);
}

.home-news-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.home-news-pin {
  padding: 3px 10px;
  border-radius: 20px;
  color: #704326;
  background: #efddc9;
}

.home-news-card h3 {
  margin: 14px 0 10px;
  line-height: 1.4;
  font-size: 20px;
  overflow-wrap: anywhere;
}

.home-news-summary {
  margin: 0;
  color: var(--muted);
  white-space: pre-line;
  overflow-wrap: anywhere;
}

.home-news-details {
  margin-top: 20px;
}

.home-news-details summary {
  width: fit-content;
  cursor: pointer;
  font-weight: 700;
  color: var(--accent-strong);
  border-radius: 4px;
}

.home-news-details summary:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 5px;
}

.home-news-body {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.home-news-empty {
  color: var(--muted);
}

.news-media-gallery { display: grid; gap: 12px; margin: 20px 0; }
.news-media-gallery.has-many { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.news-media-item { margin: 0; min-width: 0; }
.news-media-item.is-cover { grid-column: 1 / -1; }
.news-media-item img, .news-media-item video { display: block; width: 100%; max-height: 400px; aspect-ratio: 16 / 10; object-fit: contain; border-radius: 14px; background: #e8ded2; }
.news-media-item:not(.is-cover) img, .news-media-item:not(.is-cover) video { aspect-ratio: 4 / 3; }
.news-media-item figcaption { margin: 8px 2px 0; color: var(--muted); font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.news-media-open { display: block; position: relative; border-radius: 14px; overflow: hidden; }
.news-media-open:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.news-media-zoom { display: grid; place-items: center; position: absolute; right: 10px; bottom: 10px; width: 30px; height: 30px; background: #fff9; border: 1px solid #fff8; color: #493725; backdrop-filter: blur(8px); border-radius: 9px; transition: background .2s; }
.news-media-open:hover .news-media-zoom { background: #fff; }
.news-lightbox { width: min(1100px, calc(100% - 28px)); max-height: calc(100vh - 28px); padding: 46px 20px 20px; border: 1px solid #d6c7b4; border-radius: 22px; background: #fbf6ed; color: #4a3828; box-shadow: 0 28px 100px #201b1460; }
.news-lightbox::backdrop { background: #211b14b3; backdrop-filter: blur(8px); }
.news-lightbox figure { margin: 0; }
.news-lightbox img { display: block; max-width: 100%; width: auto; height: auto; max-height: 76vh; margin: auto; object-fit: contain; border-radius: 9px; }
.news-lightbox figcaption { margin-top: 14px; text-align: center; font-size: 14px; overflow-wrap: anywhere; }
.news-lightbox-close { position: absolute; top: 6px; right: 10px; width: 38px; height: 38px; border: 0; background: transparent; color: inherit; border-radius: 9px; font-size: 30px; cursor: pointer; }
.news-lightbox-close:hover { background: #eadfce; }
.news-lightbox-close:focus-visible { outline: 3px solid #a77a50; }

@media (max-width: 640px) {
  .home-news-grid {
    grid-template-columns: 1fr;
  }

  .home-news-card,
  .home-news-empty {
    padding: 22px;
  }
}
