/* Responsive news design */
*,
*::before,
*::after { box-sizing: border-box; }

body {
  min-height: 100vh;
  overflow-x: clip;
  background: #f3f6f4;
  color: #1e2a24;
  font-family: Arial, "Segoe UI", sans-serif;
}

.news-site-header,
main,
.news-footer {
  width: min(1000px, calc(100% - 24px));
  margin-inline: auto;
}

.news-site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 18px;
  padding: 12px 16px;
  color: #fff;
  background: #10172b;
  border: 1px solid #242d45;
  border-radius: 18px;
  box-shadow: 0 8px 24px #10172b18;
}

.news-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  color: #fff;
  text-decoration: none;
}

.news-brand img {
  display: block;
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
  object-fit: contain;
}

.news-brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.4;
}

.news-brand-copy strong { font-size: 1.05rem; }
.news-brand-copy small { color: #c9d1e4; }

.news-header-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.news-header-actions a {
  padding: 8px 12px;
  color: #f5f7fb;
  text-decoration: none;
  border-radius: 10px;
}

.news-header-actions a:hover { background: #ffffff18; }

.news-header-actions .news-download {
  color: #172116;
  background: #f0bd55;
  font-weight: 700;
}

main {
  max-width: 1000px;
  margin-top: 18px;
  margin-bottom: 28px;
  padding: clamp(16px, 3vw, 32px);
}

#content > h1 {
  margin: 0 0 8px;
  color: #0b6940;
  font-size: clamp(1.55rem, 3vw, 2.15rem);
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.news-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin-top: 22px;
}

.news-card {
  min-width: 0;
  padding: 14px;
  background: #fff;
  border: 1px solid #e1e9e3;
  border-radius: 18px;
  box-shadow: 0 5px 18px #14251b0c;
}

.news-card.has-image {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 250px);
  gap: 16px;
  align-items: center;
}

.news-card.has-image > img {
  grid-column: 2;
  grid-row: 1 / span 3;
  display: block;
  width: 100%;
  height: 150px;
  margin: 0;
  object-fit: cover;
  border-radius: 13px;
  background: #eef2ef;
}

.news-card h2 {
  margin: 0 0 8px;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.65;
  overflow-wrap: anywhere;
}

.news-card h2 a {
  color: #182820;
  text-decoration: none;
}

.news-card h2 a:hover { color: #087440; }

.news-card time {
  display: block;
  margin: 6px 0;
  color: #66736b;
  font-size: .88rem;
}

.news-card p {
  margin: 8px 0 0;
  color: #56645b;
  line-height: 1.75;
}

.news-card.has-image h2 { grid-column: 1; grid-row: 1; }
.news-card.has-image time { grid-column: 1; grid-row: 2; }
.news-card.has-image p { grid-column: 1; grid-row: 3; }

.news-pagination {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 24px;
}

.news-pagination a {
  padding: 9px 13px;
  color: #075b36;
  background: #eaf5ee;
  border-radius: 10px;
  text-decoration: none;
}

#content > img {
  width: auto;
  max-width: 100%;
  max-height: 70vh;
  margin-inline: auto;
  object-fit: contain;
}

#content > article {
  margin-top: 20px;
  color: #26342b;
  font-size: 1.04rem;
  line-height: 1.95;
  overflow-wrap: anywhere;
}

#content > article img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 70vh;
  margin: 18px auto;
  object-fit: contain;
}

.news-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 20px;
  margin-bottom: 24px;
  padding: 16px 4px;
  color: #647168;
  border-top: 1px solid #dce5de;
  font-size: .9rem;
}

.news-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
}

.news-footer a { color: #087440; }

@media (max-width: 640px) {
  .news-site-header {
    align-items: flex-start;
    flex-direction: column;
    padding: 12px;
  }

  .news-header-actions { width: 100%; }
  .news-header-actions a { padding: 7px 9px; }
  main { padding: 16px; }

  .news-card.has-image {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  .news-card.has-image > img {
    grid-column: 1;
    grid-row: 1;
    width: 100%;
    height: auto;
    max-height: 230px;
    aspect-ratio: 16 / 9;
  }

  .news-card.has-image h2 { grid-column: 1; grid-row: 2; }
  .news-card.has-image time { grid-column: 1; grid-row: 3; }
  .news-card.has-image p { grid-column: 1; grid-row: 4; }
}
