/* What's New 3.0 P2 — public homepage: header "What's new" link + "Recently added". Only existing evo tokens + evo-chip;
   content-named, never changed in place (docs/IMMUTABLE-ASSETS.md). Loaded by index.html only; both blocks are public-only. */

/* header link: a compact chip, secondary to Search / Menu (the site's pill language: flat, no 3-D shadow, smaller type).
   One fixed place left of Search; at the top of the public homepage it is hidden together with Search and fades in with it (never slides).
   P3 marks unread updates with .wn-trigger.has-new (yellow dot on the chip's corner); the rule ships now so P3 needs no stylesheet stage. */
.header-right .wn-trigger { display: none; }
@media (min-width: 761px) {
  .header-right .wn-trigger {
    position: relative; display: inline-flex; align-items: center; align-self: center; gap: 6px; height: 34px; min-height: 34px; padding: 0 13px 0 11px;
    border-radius: 999px; background: rgba(34,229,255,.06); border: 1px solid rgba(34,229,255,.22); box-shadow: none; color: var(--e-soft);
    font-size: 13.5px; font-weight: 650; letter-spacing: 0; line-height: 1; text-decoration: none; white-space: nowrap;
    transition: opacity .2s, background-color .14s, border-color .14s, color .14s, transform .14s var(--e-ease);
  }
  .header-right .wn-trigger svg { width: 16px; height: 16px; color: var(--e-cy); flex: none; }
  .header-right .wn-trigger:hover { color: var(--e-text); background: rgba(34,229,255,.12); border-color: rgba(34,229,255,.45); }
  .header-right .wn-trigger:active { transform: translateY(1px); }
  .header-right .wn-trigger:focus-visible { outline: 2px solid var(--e-cy); outline-offset: 2px; }
  .header-right .wn-trigger.has-new::after { content: ""; position: absolute; top: -2px; right: -2px; width: 8px; height: 8px; border-radius: 50%;
    background: #ffd23f; box-shadow: 0 0 0 2px var(--e-bg, #0b0f17), 0 0 8px rgba(255,210,63,.55); }
  body.home-v3:not(.evo-past) .header-right .wn-trigger { opacity: 0; visibility: hidden; pointer-events: none; }
}
@media (min-width: 761px) and (max-width: 899px), (min-width: 761px) and (max-height: 500px) {
  body.evo-scrolled .header-right .wn-trigger { background: rgba(16,21,31,.92); }
}

/* type pill (same as the archive) */
.wn-k { display: inline-flex; align-items: center; gap: 6px; flex: none; font-size: 12px; font-weight: 700; line-height: 1; padding: 5px 9px 5px 8px; border-radius: 999px; white-space: nowrap; }
.wn-k::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.wn-k-n { color: var(--e-notes); background: var(--e-notes-bg); box-shadow: inset 0 0 0 1px var(--e-notes-line); }
.wn-k-s { color: var(--e-sol); background: var(--e-sol-bg); box-shadow: inset 0 0 0 1px var(--e-sol-line); }
.wn-k-p { color: var(--e-pyq); background: var(--e-pyq-bg); box-shadow: inset 0 0 0 1px var(--e-pyq-line); }
.wn-k-v { color: var(--e-cy); background: rgba(34,229,255,.10); box-shadow: inset 0 0 0 1px var(--e-hl); }

/* Recently added: a short timeline, the archive's language */
.wnh { padding: clamp(8px, 2vw, 16px) var(--v3-gut-r, var(--e-gut)) clamp(48px, 7vw, 80px) var(--v3-gut-l, var(--e-gut)); }
.wnh-in { max-width: var(--v3-w, 1040px); margin: 0 auto; }
.wnh-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 24px; }
.wnh-title { margin: 0; }
.wnh-all { display: inline !important; padding: 0 !important; min-height: 0 !important; color: var(--e-cy); font-size: 15px; font-weight: 650; text-decoration: none; white-space: nowrap; }
.wnh-all:hover { text-decoration: underline; text-underline-offset: 3px; }
.wnh-all:focus-visible { outline: 2px solid var(--e-cy); outline-offset: 3px; border-radius: 4px; }
.wnh-list { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 8px; }

.wnh-e { position: relative; min-width: 0; padding: 18px 18px 18px; border-radius: var(--c-r-card); transition: background-color var(--c-base) ease; -webkit-tap-highlight-color: transparent; }
.wnh-e::before { content: ""; position: absolute; width: 10px; height: 10px; border-radius: 50%; background: var(--e-bg); box-shadow: 0 0 0 2px var(--e-ledge); }
.wnh-e:hover, .wnh-e:active { background: var(--e-s1); }
.wnh-e:hover::before, .wnh-e:active::before { background: var(--e-cy); box-shadow: 0 0 0 2px var(--e-cy), 0 0 12px var(--e-hl); }
.wnh-d { margin: 0 0 6px; font-size: 13px; font-weight: 700; color: var(--e-soft); }
.wnh-c { margin: 0; font-size: 19px; font-weight: 720; letter-spacing: -0.02em; line-height: 1.25; overflow-wrap: anywhere; }
.wnh-c a { display: inline !important; padding: 0 !important; min-height: 0 !important; color: var(--e-text); text-decoration: none; }
.wnh-c a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.wnh-e:hover .wnh-c a { color: var(--e-cy); }
.wnh-c .wn-go { display: inline-block; vertical-align: -3px; margin-left: 2px; color: var(--e-cy); opacity: .7; transition: transform var(--c-base) var(--c-ease-out), opacity var(--c-base); }
.wnh-e:hover .wn-go { transform: translateX(3px); opacity: 1; }
.wnh-c a:focus-visible { outline: 2px solid var(--e-cy); outline-offset: 3px; border-radius: 4px; }
@supports selector(:has(*)) {
  .wnh-c a:focus-visible { outline: none; }
  .wnh-e:has(a:focus-visible) { outline: 2px solid var(--e-cy); outline-offset: 2px; background: var(--e-s1); }
}
.wnh-m { margin: 4px 0 12px; font-size: 13px; color: var(--e-muted); }
.wnh-m b { font-weight: 650; color: var(--e-soft); }
.wnh-r { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 15px; line-height: 1.35; color: var(--e-soft); overflow-wrap: anywhere; }
.wnh-rt { margin: 0 2px 0 0; min-width: 0; }
.wnh-r .evo-chip { font-size: 11px; padding: 3px 6px; }
.wnh-more { font-size: 13px; color: var(--e-muted); }

/* wide: three entries on a horizontal rail */
@media (min-width: 900px) {
  .wnh-list { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 16px; border-top: 2px solid var(--e-line2); padding-top: 0; }
  .wnh-e { padding-top: 26px; margin-top: -2px; }
  .wnh-e::before { left: 18px; top: -6px; }
}
/* narrower: a vertical rail, like the archive on phones */
@media (max-width: 899px) {
  .wnh-list { gap: 4px; padding-left: 18px; margin-left: 4px; border-left: 2px solid var(--e-line2); }
  .wnh-e { padding: 12px 12px 14px; margin-left: -6px; }
  .wnh-e::before { left: -17px; top: 21px; }
  .wnh-c { font-size: 18px; }
}
@media (prefers-reduced-motion: reduce) { .wnh-e, .wnh-c .wn-go, .header-right .wn-trigger { transition: none; } }
