/* news.css */

/* ── Hero ───────────────────────────────────────────────── */
.news-hero {
  background: linear-gradient(
    135deg,
    var(--color-blue-950) 0%,
    var(--color-blue-700) 100%
  );
  padding-block: var(--space-16) var(--space-12);
}
.news-hero__heading {
  font-size: clamp(var(--text-4xl), 6vw, var(--text-5xl));
  font-weight: var(--weight-extra);
  color: var(--color-text-hero-header);
  margin-bottom: var(--space-3);
}
.news-hero__sub {
  font-size: var(--text-lg);
  color: var(--color-hero-body-text);
  max-width: 60ch;
  line-height: var(--leading-relaxed);
}
.news-hero__sub a {
  color: var(--color-hero-em);
}

/* ── Feed layout ────────────────────────────────────────── */
.news-feed {
  padding-block: var(--space-16);
}
.news-feed__inner {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: var(--space-12);
  align-items: start;
}
.news-feed__empty {
  font-size: var(--text-lg);
  color: var(--color-text-muted);
  padding: var(--space-10);
  text-align: center;
  border: 2px dashed var(--color-border);
  border-radius: var(--radius-lg);
}

/* ── Announcement card ──────────────────────────────────── */
.announcement {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  margin-bottom: var(--space-5);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.announcement--pinned {
  border-left: 4px solid var(--color-pinned-border);
  background-color: var(--color-pinned-bg);
}

/* Category accent colors */
.announcement--registration {
  border-top: 3px solid var(--color-primary);
}
.announcement--cancellation {
  border-top: 3px solid var(--color-cancellation);
}
.announcement--volunteer {
  border-top: 3px solid var(--color-volunteer);
}

.announcement__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-2);
}
.announcement__pin {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  color: var(--color-pinned-text);
}
.announcement__category {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--color-text-muted);
  background: var(--color-surface);
  padding: 2px var(--space-2);
  border-radius: var(--radius-sm);
}
.announcement__sport-tag {
  font-size: var(--text-xs);
  font-weight: var(--weight-semi);
  color: var(--color-primary);
  background: var(--color-primary-light);
  padding: 2px var(--space-2);
  border-radius: var(--radius-sm);
  text-decoration: none;
}
.announcement__sport-tag:hover {
  text-decoration: underline;
}
.announcement__date {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-left: auto;
}
.announcement__heading {
  font-size: var(--text-xl);
  font-weight: var(--weight-bold);
  color: var(--color-primary-dark);
  line-height: var(--leading-tight);
}
.announcement__body {
  font-size: var(--text-base);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
}
.announcement__cta {
  align-self: flex-start;
}

/* ── Sidebar ────────────────────────────────────────────── */
.news-sidebar {
  position: sticky;
  top: calc(var(--nav-height) + var(--space-6));
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}
.news-sidebar__card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  box-shadow: var(--shadow-sm);
}
.news-sidebar__heading {
  font-size: var(--text-base);
  font-weight: var(--weight-bold);
  color: var(--color-primary-dark);
}
.news-sidebar__card p {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
}
.news-sidebar__card ul {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.news-sidebar__card li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  font-size: var(--text-sm);
}
.news-sidebar__sport-link {
  color: var(--sport-primary, #1a6b2e);
  font-weight: var(--weight-bold);
}
.news-sidebar__season {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

/* ── Registration status list ───────────────────────────── */
.reg-status-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.reg-status-item {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: var(--space-1) var(--space-2);
  align-items: center;
}
.reg-status-item__link {
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  color: var(--sport-primary, #1a6b2e);
  grid-row: 1;
}
.reg-status-item__link:hover {
  text-decoration: underline;
}
.reg-status-item__badge {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  padding: 2px var(--space-2);
  border-radius: var(--radius-full);
  grid-row: 1;
  white-space: nowrap;
}
.reg-status-item__badge--open {
  background: var(--color-success-bg);
  color: var(--color-success-text);
}
.reg-status-item__badge--closed {
  background: var(--color-surface);
  color: var(--color-text-secondary);
}
.reg-status-item__opens {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  grid-column: 1 / -1;
  grid-row: 2;
}

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 900px) {
  .news-feed__inner {
    grid-template-columns: 1fr;
  }
  .news-sidebar {
    position: static;
  }
}
