/* ==========================================================================
   Design refresh (2026-10-31). Loaded last on every page by scripts/build.py.
   Accessibility contrast (WCAG 2.2 AA), touch target size, caption legibility.
   Light-mode colors are scoped with html:not([data-theme="dark"]) so the
   existing dark-mode rules keep working.
   ========================================================================== */

/* ---------- Text contrast (each pair checked at >= 4.5:1, large text >= 3:1) ---------- */
.falcon-footer-note,
.falcon-footer-bottom p { color: #94a3b8; }                          /* 7.1:1 on #101522 */

html:not([data-theme="dark"]) .falcon-result-card__date { color: #64748b; }   /* 4.8:1 */
html:not([data-theme="dark"]) .falcon-toc-title,
html:not([data-theme="dark"]) .falcon-article-layout .falcon-toc-title { color: #64748b; }
html:not([data-theme="dark"]) .falcon-author-bio { color: #475569; }           /* 7.1:1 on #f6f7fb */
html:not([data-theme="dark"]) .falcon-search-hero__count { color: #475569; }

.ff-fresh-num { color: #7c83f3; }                                     /* 3.3:1, large display numerals */

/* "Written by" line in the author box is a paragraph, not a heading. */
p.falcon-author-name { margin: 0 0 4px; font-size: 18px; line-height: 1.3; font-weight: 800; }

/* ---------- Photo captions: readable size, upright, darker ---------- */
.entry-content figcaption,
.falcon-article-content figcaption,
.ff-post-hero figcaption {
  font-size: 13.5px;
  line-height: 1.5;
  font-style: normal;
}
html:not([data-theme="dark"]) .entry-content figcaption,
html:not([data-theme="dark"]) .falcon-article-content figcaption,
html:not([data-theme="dark"]) .ff-post-hero figcaption { color: #475569; }

/* ---------- Touch targets: at least 24x24 CSS px (WCAG 2.5.8) ---------- */
/* Category labels keep their text-label look; only the tap height grows. */
a.category-badge,
a.category-badge.category-badge-sm {
  display: inline-flex;
  align-items: center;
  min-height: 24px !important;
}
.ff-home-more {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 32px;
}
button[type="submit"][aria-label="Submit search"] { min-width: 32px; min-height: 32px; }

/* ---------- Visible keyboard focus everywhere ---------- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid #5541f8;
  outline-offset: 2px;
}
[data-theme="dark"] a:focus-visible,
[data-theme="dark"] button:focus-visible,
[data-theme="dark"] input:focus-visible,
[data-theme="dark"] summary:focus-visible { outline-color: #a5b4fc; }

/* ---------- Reading comfort ---------- */
html { scroll-padding-top: 96px; }                 /* anchored headings clear the sticky header */
.entry-content img,
.falcon-article-content img { height: auto; }

/* Screen-reader-only text, available on every page (not just the homepage). */
.falcon-visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
