/* news page (news.html) + blue nav button. Reuses .rel-card, .rel-filter, .rel-badge */

/* nav button: same shape as the other round buttons (.nav-logo), primary color */
.nav-toggles .nav-news { background: var(--md-primary); color: var(--md-on-primary); }

/* grouped bubbles: big corners on the ends, small ones between (like the pushes list) */
.nw-row { flex-direction: column; align-items: stretch; gap: 0; padding: 1rem 1.2rem; margin-bottom: 0; }
.nw-head { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; }
.nw-emoji { font-size: 1.6rem; line-height: 1; }
.nw-title { font-family: var(--font-display); font-size: 1.1rem; font-weight: 700; margin: 0; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.nw-date { font-size: .8rem; opacity: .75; margin: .25rem 0 0; }
.nw-body { margin: .7rem 0 0; font-size: .95rem; line-height: 1.55; overflow-wrap: anywhere; }
.nw-body p { margin: 0 0 .5rem; }
.nw-body ul { margin: 0 0 .5rem; padding-left: 1.3rem; }
.nw-body li { margin: .15rem 0; }
.nw-body .nw-h { font-family: var(--font-display); margin: .6rem 0 .25rem; line-height: 1.25; }
.nw-body .nw-h1 { font-size: 1.25rem; } .nw-body .nw-h2 { font-size: 1.12rem; } .nw-body .nw-h3 { font-size: 1.02rem; }
.nw-body code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .88em; padding: .08em .35em; border-radius: 6px; background: var(--md-surface-container-highest, rgba(127,127,127,.18)); }
.nw-body mark { background: color-mix(in srgb, var(--md-primary) 28%, transparent); color: inherit; padding: 0 .15em; border-radius: 4px; }
.nw-body .nw-img { display: block; max-width: 100%; height: auto; border-radius: 12px; margin: .4rem 0; }
.nw-table { overflow-x: auto; margin: .3rem 0 .6rem; }
.nw-table table { border-collapse: collapse; font-size: .9rem; }
.nw-table th, .nw-table td { border: 1px solid var(--md-outline-variant, rgba(127,127,127,.35)); padding: .35rem .6rem; text-align: left; vertical-align: top; }
.nw-table th { background: var(--md-surface-container-highest, rgba(127,127,127,.15)); font-weight: 700; }
.nw-body a { color: var(--md-primary); text-decoration: underline; }
.nw-row.is-alert .rel-badge { background: var(--md-error-container, #FFDAD6); color: var(--md-on-error-container, #410002); }

/* mobile: same toolbar on news, pushes and versions pages */
@media (max-width: 640px) {
  .rel-toolbar { flex-direction: row; flex-wrap: wrap; align-items: center; gap: .6rem; }
  /* all filters visible: they wrap onto several lines */
  .rel-toolbar .rel-filter { flex: 1 1 100%; width: 100%; flex-wrap: wrap; gap: 6px; }
  .rel-toolbar .rel-filter .rel-filter-btn { flex: 1 1 auto; padding: 0 .9rem; white-space: nowrap; border-radius: var(--r-chip); min-height: 40px; }
  /* translate button on the same line as the search bar */
  .rel-toolbar .cm-tr-btn { flex: 0 0 auto; }
  /* versions page: translate button + search share one line */
  .rel-layout { flex-direction: row; flex-wrap: wrap; align-items: center; }
  .rel-layout > * { flex: 1 1 100%; min-width: 0; }
  .rel-layout > .cm-tr-btn { flex: 0 0 auto; }
  .rel-layout > .rel-search { flex: 1 1 0; width: auto; }
  .rel-toolbar .cm-search, .rel-toolbar .rel-search { flex: 1 1 0; min-width: 0; width: auto; max-width: none; }
  .nw-row { padding: .9rem 1rem; }
  .nw-title { font-size: 1rem; flex-basis: 60%; }
}
/* small phones: five nav buttons must fit */
@media (max-width: 480px) {
  .nav-toggles { gap: .25rem; }
  .nav-toggles .nav-logo { width: 40px; height: 40px; }
}
.nw-body ol { margin: 0 0 .5rem; padding-left: 1.5rem; }
.nw-body blockquote { margin: 0 0 .5rem; padding: .2rem .9rem; border-left: 3px solid currentColor; opacity: .8; }
