.news-archive-filter-form {
  margin: 0;
}

.news-archive-filter-panel > .r-panel__body {
  padding: 0.9rem 1rem 1rem;
}

.news-archive-filter-grid {
  display: grid;
  grid-template-columns: minmax(13.5rem, 0.78fr) minmax(0, 1.22fr);
  gap: 1rem;
  align-items: start;
}

.news-archive-filter-group {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.news-archive-filter-group__title {
  display: flex;
  width: 100%;
  margin: 0 0 0.55rem;
  padding: 0 0 0.42rem;
  border-bottom: 1px solid var(--r-line);
  align-items: center;
  gap: 0.42rem;
  color: var(--r-ink);
  font: 800 0.72rem/1.2 var(--r-font-ui);
  letter-spacing: 0.065em;
  text-transform: uppercase;
}

.news-archive-filter-group__title i {
  color: var(--r-gold-700);
  font-size: 0.78rem;
}

.news-archive-date-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.news-archive-date-grid .r-field {
  gap: 0.3rem;
}

.news-archive-date-grid .r-field__label {
  font-size: 0.64rem;
}

.news-archive-date-grid .r-field input[type='date'] {
  min-height: 2.35rem;
  padding: 0.48rem 0.58rem;
  font-size: 0.8rem;
}

.news-archive-category-options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.42rem;
}

.news-archive-category-option {
  display: inline-flex;
  min-height: 2.2rem;
  padding: 0.3rem 0.56rem;
  border: 1px solid rgba(105, 83, 61, 0.28);
  border-radius: 999px;
  align-items: center;
  gap: 0.4rem;
  color: var(--r-ink-soft);
  background: rgba(255, 255, 255, 0.5);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.45);
  box-sizing: border-box;
  font: 750 0.72rem/1.1 var(--r-font-ui);
  cursor: pointer;
  transition:
    border-color 150ms ease,
    background-color 150ms ease,
    box-shadow 150ms ease,
    color 150ms ease;
}

.news-archive-category-option:hover {
  border-color: rgba(163, 110, 43, 0.52);
  color: var(--r-ink);
  background: rgba(255, 255, 255, 0.78);
}

.news-archive-category-option:focus-within {
  outline: 0;
  box-shadow: var(--r-focus);
}

.news-archive-category-option:has(input:checked) {
  border-color: rgba(163, 110, 43, 0.7);
  color: #563812;
  background: rgba(238, 198, 118, 0.28);
  box-shadow: inset 0 0 0 1px rgba(255, 244, 211, 0.58);
}

.news-archive-category-option input {
  width: 0.9rem;
  height: 0.9rem;
  margin: 0;
  flex: 0 0 auto;
  accent-color: var(--r-gold-600);
}

.news-archive-category-option img {
  width: 1.12rem;
  height: 1.12rem;
  flex: 0 0 auto;
  object-fit: contain;
}

.news-archive-filter-errors {
  margin: 0.8rem 0 0;
}

.news-archive-filter-actions {
  margin-top: 0.8rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--r-line);
}

.news-archive-filter-actions .r-button {
  min-height: 2.35rem;
  padding: 0.55rem 0.82rem;
  font-size: 0.7rem !important;
}

.news-archive-results-panel > .r-panel__body {
  padding: 0.65rem;
}

.news-archive-results-count {
  color: rgba(255, 250, 240, 0.72);
  font: 700 0.7rem/1.2 var(--r-font-ui);
  white-space: nowrap;
}

.news-archive-results-count strong {
  color: var(--r-gold-300);
  font-size: 0.82rem;
}

.news-archive-list {
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--r-line);
  border-radius: var(--r-radius-md);
  list-style: none;
  background: rgba(255, 255, 255, 0.36);
}

.news-archive-list__item + .news-archive-list__item {
  border-top: 1px solid var(--r-line);
}

.news-archive-entry {
  display: grid;
  min-height: 2.5rem;
  padding: 0.35rem 0.6rem;
  grid-template-columns: 1.35rem minmax(0, 1fr) 0.65rem;
  align-items: center;
  gap: 0.55rem;
  color: var(--r-ink) !important;
  background: rgba(255, 255, 255, 0.28);
  box-sizing: border-box;
  text-decoration: none !important;
  transition:
    background-color 150ms ease,
    box-shadow 150ms ease;
}

.news-archive-list__item:nth-child(even) .news-archive-entry {
  background: rgba(221, 195, 157, 0.23);
}

.news-archive-entry:hover,
.news-archive-entry:focus-visible {
  color: var(--r-ink) !important;
  background: rgba(210, 162, 91, 0.18);
  box-shadow: inset 3px 0 var(--r-gold-500);
  outline: 0;
}

.news-archive-entry__icon {
  display: grid;
  width: 1.25rem;
  height: 1.25rem;
  place-items: center;
}

.news-archive-entry__icon img {
  display: block;
  width: 1.25rem;
  height: 1.25rem;
  object-fit: contain;
}

.news-archive-entry__body {
  display: grid;
  min-width: 0;
  grid-template-columns: 5.8rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.55rem;
}

.news-archive-entry__date {
  color: var(--r-ink-soft);
  font: 650 0.68rem/1.2 var(--r-font-status);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.news-archive-entry__title {
  min-width: 0;
  overflow: hidden;
  color: #17568e;
  font: 750 0.78rem/1.25 var(--r-font-ui);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.news-archive-entry__category {
  display: inline-flex;
  max-width: 9rem;
  padding: 0.18rem 0.44rem;
  overflow: hidden;
  border: 1px solid rgba(105, 83, 61, 0.18);
  border-radius: 999px;
  align-items: center;
  color: var(--r-ink-soft);
  background: rgba(255, 255, 255, 0.45);
  font: 750 0.61rem/1 var(--r-font-ui);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.news-archive-entry__arrow {
  color: rgba(105, 83, 61, 0.58);
  font-size: 0.6rem;
  transition: transform 150ms ease;
}

.news-archive-entry:hover .news-archive-entry__arrow,
.news-archive-entry:focus-visible .news-archive-entry__arrow {
  color: var(--r-gold-700);
  transform: translateX(2px);
}

.news-archive-list__empty {
  padding: 1.25rem;
}

.news-archive-list__empty .r-empty-state {
  display: grid;
  gap: 0.35rem;
  text-align: center;
}

.news-archive-pagination {
  margin: 0.75rem 0 0;
}

.news-article-footer {
  display: flex;
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--r-line);
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.news-article-footer__admin {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.news-article-footer__admin form {
  margin: 0;
}

@media (max-width: 700px) {
  .news-archive-filter-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .news-archive-entry {
    min-height: 3rem;
    padding: 0.45rem 0.55rem;
  }

  .news-archive-entry__body {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.2rem 0.45rem;
  }

  .news-archive-entry__title {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .news-archive-entry__date {
    grid-column: 1;
    grid-row: 2;
  }

  .news-archive-entry__category {
    grid-column: 2;
    grid-row: 2;
  }
}

@media (max-width: 520px) {
  .news-archive-date-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .news-archive-filter-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .news-archive-filter-actions .r-button {
    width: 100%;
  }

  .news-archive-entry__category {
    max-width: 7.5rem;
  }

  .news-article-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .news-article-footer .r-button {
    width: 100%;
  }

  .news-article-footer__admin {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .news-article-footer__admin form,
  .news-article-footer__admin button {
    width: 100%;
  }
}
