/* AI Notices — notice pages and the /notices index.
   Layers on /read/article.css: the hero, prose and chip styles are shared, so only
   notice-specific elements live here. Design system v3 (see DESIGN.md): flat colours,
   no gradients, no resting glow — depth is a hover response only. */

/* ── Severity ──────────────────────────────────────────────────────────────
   Severity is the one place this section uses colour to mean something, so it
   is the only non-teal ink on the page. Fills carry white text at AA contrast. */
.notice-severity {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 4px;
  color: #fff;
  white-space: nowrap;
}
.notice-severity--critical    { background: #8c1d18; }
.notice-severity--significant { background: #8a5100; }
.notice-severity--notable     { background: var(--primary-strong); }
.notice-severity--minor       { background: #5e6668; }

.notice-vendor,
.notice-date {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: .02em;
}
/* The article hero is petrol, where --text-muted (#5e6668) falls to 1.4:1 and is
   effectively invisible. --on-petrol is the token meant for muted text on that
   ground (6.06:1). Measured, not guessed. */
.article-hero .notice-vendor,
.article-hero .notice-date {
  color: var(--on-petrol);
}
.article-hero .notice-vendor a { color: inherit; text-underline-offset: 3px; }

/* ── Links inside cards ──
   A card is not one big link, because its company and action tags are links too. The
   headline link stretches over the whole card with ::after; the tags sit above it. */
.notice-stretch { color: inherit; text-decoration: none; }
.notice-stretch::after { content: ''; position: absolute; inset: 0; border-radius: inherit; }
.notice-stretch:focus-visible { outline: none; }
.notice-stretch:focus-visible::after { outline: 2px solid var(--primary-strong); outline-offset: -2px; }
.notice-tag { position: relative; z-index: 1; text-decoration: none; }
.notice-tag:hover, .notice-tag:focus-visible { text-decoration: underline; text-underline-offset: 3px; }
a.notice-vendor:hover { color: var(--primary-dark); }

/* ── Browse: company pages and the action-required list ── */
.notice-browse { display: flex; flex-direction: column; gap: 10px; margin: 0 0 36px; }
.browse-group { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.browse-label {
  min-width: 92px;
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted);
}
.browse-tag {
  padding: 7px 12px;
  font-family: var(--mono); font-size: 13px; color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  text-decoration: none;
  transition: border-color .15s ease;
}
.browse-tag small { margin-left: 4px; font-size: 12px; color: var(--text-muted); }
.browse-tag:hover { border-color: var(--primary-strong); }
.browse-tag[aria-current="page"] { background: var(--primary-strong); border-color: var(--primary-strong); color: #fff; }
.browse-tag[aria-current="page"] small { color: rgba(255,255,255,.85); }
.notice-browse + .month { margin-top: 0; }
.notice-browse + .month .month-head { border-top: 0; padding-top: 0; }
.notice-empty { color: var(--text-subtle); }
.notice-archive-link { margin: 32px 0 0; }
.notice-archive-link a {
  display: inline-block; padding: 9px 14px;
  font-family: var(--mono); font-size: 13px; color: var(--text); text-decoration: none;
  background: var(--surface); border: 1px solid var(--border-strong); border-radius: 8px;
}
.notice-archive-link a:hover { border-color: var(--primary-strong); }
.notice-archive-link small { margin-left: 4px; font-size: 12px; color: var(--text-muted); }
@media (max-width: 720px) {
  .browse-label { min-width: 0; width: 100%; }
}

/* ── What to do ───────────────────────────────────────────────────────────
   The single most important block on the page for a teacher, so it gets the
   only tinted panel. Left rule rather than a full border — flat at rest. */
.notice-action {
  margin: 28px 0;
  padding: 16px 20px;
  background: #fdf3e7;
  border-left: 3px solid #8a5100;
  border-radius: 0 8px 8px 0;
}
.notice-action--none {
  background: var(--bg-alt);
  border-left-color: var(--rule);
}
.notice-action-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.notice-action-title .material-symbols-outlined { font-size: 18px; }
.notice-action p { margin: 0; }

/* ── Evidence ─────────────────────────────────────────────────────────────
   Verbatim vendor text. Styled as a quote deliberately: the credibility of the
   whole product rests on a reader being able to see the source words. */
.notice-quote {
  margin: 16px 0;
  padding: 14px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--primary);
  border-radius: 0 8px 8px 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-subtle);
}
.notice-quote a {
  display: block;
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 11px;
  word-break: break-all;
  color: var(--primary-dark);
}

.notice-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 28px 0 0;
}
.notice-obligation {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .04em;
  padding: 5px 10px;
  border: 1px solid var(--border-strong);
  border-radius: 4px;
  color: var(--text-muted);
}

.notice-disclaimer {
  margin: 32px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-muted);
}

/* ── Index ────────────────────────────────────────────────────────────────
   Structured by month (see gen.py index_page). The index runs on the site's
   1200px container, wider than an article, so the hero on this page widens
   to match and the grid lines up with it. */
.notices-head-inner,
.notice-list-inner { max-width: 1200px; }
/* The listing pages open with the same light page head as pricing and the FAQ: a mono
   label, a heavy heading with one accented phrase, and a muted lede on the page canvas.
   Only a single notice, which reads as an article, keeps the dark article hero. The
   head is shorter than those pages' because a listing is scanned, and the filters sit
   close underneath. */
.notices-head { padding: 48px 0 36px; border-bottom: 1px solid var(--border-strong); }
.notices-head-inner { margin: 0 auto; padding: 0 32px; }
.notices-head .section-label {
  display: block; margin-bottom: 16px;
  font-family: var(--mono); font-size: 12.5px; font-weight: 700;
  letter-spacing: .09em; text-transform: uppercase; color: var(--primary-dark);
}
.notices-head .page-h1 {
  font-family: 'Public Sans', sans-serif; font-weight: 900;
  font-size: clamp(34px, 4vw, 54px); line-height: 1.06; letter-spacing: -.04em;
  color: var(--text); max-width: 30ch; margin: 0 0 18px;
}
.notices-head .page-h1 .accent { color: var(--primary-dark); }
.notices-head .page-sub {
  margin: 0; font-size: 18px; line-height: 1.65; color: var(--text-muted); max-width: 64ch;
}
.notices-head .breadcrumb { color: var(--text-muted); }
.notices-head .breadcrumb:hover { color: var(--text); }
.notices-head + .article-body { padding-top: 28px; }
@media (max-width: 720px) {
  .notices-head { padding: 36px 0 28px; }
  .notices-head-inner { padding: 0 20px; }
}
.notice-list-inner {
  margin: 0 auto;
  padding: 0 32px 72px;
}
.notice-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 14px;
}
.notice-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 20px 22px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;         /* v3 card radius */
  text-decoration: none;
  color: inherit;
  transition: border-color .15s ease, box-shadow .15s ease;
}
/* Flat at rest — depth only on hover (DESIGN.md Flat-At-Rest Rule). */
.notice-card:hover {
  border-color: var(--border-strong);
  box-shadow: 0 10px 28px rgba(15,49,51,.06);
}
.notice-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.notice-card-title {
  font-family: 'Public Sans', sans-serif;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1.3;
  margin: 0 0 8px;
  color: var(--text);
}
.notice-card-lede {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-subtle);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.notice-card-action {
  display: inline-block;
  margin-top: auto;
  padding-top: 14px;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: #8a5100;
}
.notice-card-action--none { color: var(--text-muted); }
a.notice-card-action { align-self: flex-start; }

/* ── Month sections ── */
.month { margin-top: 44px; }
.month--current { margin-top: -16px; }
.month-head {
  display: flex; align-items: baseline; gap: 14px;
  margin: 0 0 16px; padding-top: 16px;
  border-top: 1px solid var(--rule);   /* a separator the reader must see: --rule, not --border */
}
.month--current .month-head { border-top: 0; padding-top: 0; }
.month-head h2 {
  margin: 0;
  font-family: 'Public Sans', sans-serif; font-size: 22px; font-weight: 800;
  letter-spacing: -.02em; color: var(--text);
}
.month-head small { font-family: var(--mono); font-size: 12.5px; color: var(--text-muted); }
.month-sub {
  margin: 22px 0 12px;
  font-family: var(--mono); font-size: 12.5px; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: var(--text-subtle);
}
.month-sub--critical { color: #8c1d18; }
.month-sub small { font-weight: 500; letter-spacing: .02em; text-transform: none; color: var(--text-muted); }

/* ── Critical panel (current month) ──
   One critical shown in full and rotating; every critical for the month listed beside
   it. Rotation keyframes are emitted per page by gen.py because the timing depends on
   the count. Nothing here needs script. */
.crit {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 14px;
}
.crit-head {
  display: flex; align-items: baseline; gap: 14px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--rule);
  font-family: var(--mono); font-size: 12.5px; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: #8c1d18;
}
.crit-head small { font-weight: 500; letter-spacing: .02em; text-transform: none; color: var(--text-muted); }
.crit-split { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
.crit-stage { display: grid; }
.crit-lead {
  grid-area: 1 / 1;              /* all leads stack in one cell; the tallest sets the height */
  min-height: 304px;             /* room for three rows beside it before the list scrolls */
  padding: 26px 28px 24px;
  display: flex; flex-direction: column;
  position: relative;
  text-decoration: none; color: inherit;
  opacity: 0; visibility: hidden;
}
.crit-lead--0 { opacity: 1; visibility: visible; }   /* shown before rotation starts, and with one critical */
.crit-lead .notice-card-meta { margin-bottom: 14px; }
.crit-lead .notice-card-title {
  font-size: 26px; font-weight: 900; letter-spacing: -.03em; line-height: 1.12; margin: 0 0 12px;
}
.crit-lead .notice-card-lede { display: block; -webkit-line-clamp: unset; font-size: 16px; line-height: 1.6; }
.crit-lead .notice-card-action { padding-top: 18px; }
.crit-lead:hover .notice-card-title { color: var(--primary-dark); }

/* The side list scrolls inside the lead's height: absolutely positioned so it adds no
   height of its own, so the panel is always exactly as tall as the lead. */
.crit-side { border-left: 1px solid var(--rule); position: relative; min-height: 0; }
.crit-side-scroll {
  position: absolute; inset: 0;
  overflow-y: auto; overscroll-behavior: contain;
  scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent;
}
.crit-side-scroll::-webkit-scrollbar { width: 8px; }
.crit-side-scroll::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 4px; border: 2px solid var(--surface); }
.crit-side-scroll::-webkit-scrollbar-track { background: transparent; }
.crit-side-label {
  position: sticky; top: 0; z-index: 2;   /* above the rows' tag links as they scroll under */
  display: flex; justify-content: space-between; gap: 12px;
  padding: 14px 22px 10px;
  background: var(--surface);
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted);
}
.crit-side-label small { font-weight: 500; letter-spacing: .02em; text-transform: none; }
/* Fade at the foot hints that the list continues. */
.crit-side::after {
  content: ''; position: absolute; left: 0; right: 8px; bottom: 0; height: 28px;
  background: linear-gradient(to bottom, rgba(255,255,255,0), var(--surface));
  pointer-events: none;
}

/* Critical rows: the side list in the current month, the table in earlier months */
.crit-row {
  position: relative;
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center;
  column-gap: 18px; padding: 16px 24px;
  border-top: 1px solid var(--border);
  text-decoration: none; color: inherit;
  transition: background .15s ease;
}
.crit-row:hover { background: var(--canvas); }
.crit-row-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.crit-row-title {
  text-decoration: none;
  font-family: 'Public Sans', sans-serif; font-size: 18px; font-weight: 800;
  letter-spacing: -.02em; line-height: 1.3; color: var(--text);
}
.crit-row .notice-card-action { margin: 0; padding: 0; }
.crit-side .crit-row { padding: 12px 22px; grid-template-columns: minmax(0, 1fr); row-gap: 4px; }
.crit-side .crit-row-title { font-size: 16px; }
.crit-side .crit-row:first-of-type { border-top: 0; }
.crit-table {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 14px;
}
.crit-table .crit-row:first-of-type { border-top: 0; }

/* Rotation control: pause while the pointer is over the panel or a keyboard user has
   focus inside it (WCAG 2.2.2); off entirely under reduced motion, showing the newest. */
.crit:hover .crit-lead, .crit:focus-within .crit-lead,
.crit:hover .crit-side .crit-row, .crit:focus-within .crit-side .crit-row { animation-play-state: paused; }
@media (prefers-reduced-motion: reduce) {
  .crit-lead, .crit-side .crit-row { animation: none !important; }
  .crit-lead:not(.crit-lead--0) { display: none; }
}
@media (max-width: 900px) {
  .crit-split { grid-template-columns: 1fr; }
  .crit-side { border-left: 0; border-top: 1px solid var(--rule); height: 300px; }
}

.notice-cta {
  margin: 48px 0 0;
  padding: 28px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 14px;
  text-align: center;
}
.notice-cta h2 { margin: 0 0 8px; font-size: 21px; }
.notice-cta p  { margin: 0 auto 18px; max-width: 46ch; color: var(--text-subtle); }

@media (max-width: 720px) {
  .notice-list-inner { padding: 0 20px 56px; }   /* matches the 720px narrow-padding rule */
  .notice-card { padding: 18px; }
}
