﻿/* AIFoxNews public site. Local styles only: no external fonts, CDNs or scripts. */
:root {
  --paper: #fbfaf6;
  --ink: #15171c;
  --text: #2b2f38;
  --muted: #6d7078;
  --rule: #d9d4c8;
  --rule-soft: #e9e5db;
  --fox: #d9480f;
  --fox-soft: #fbe9df;
  --plate: #15171c;
  --serif: Georgia, "Iowan Old Style", "Palatino Linotype", Cambria, "Times New Roman", serif;
  --sans: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--text); font-family: var(--sans); line-height: 1.6; }
a { color: inherit; text-decoration: none; }
.wrap { width: 100%; max-width: 1360px; margin-left: auto; margin-right: auto; padding-left: 32px; padding-right: 32px; }
.muted { color: var(--muted); font-size: .95rem; }
.center { text-align: center; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
:focus-visible { outline: 3px solid #f2b79b; outline-offset: 2px; }

/* category colours (used for tags and top rules) */
.c-models { --cc: #d9480f; }
.c-research { --cc: #0b8a74; }
.c-business { --cc: #b7791f; }
.c-chips { --cc: #566074; }
.c-robotics { --cc: #7c4dbd; }
.c-regulation { --cc: #6b6559; }
.c-crypto_ai { --cc: #c2294a; }
.c-tools { --cc: #2f8f4e; }

/* masthead: wordmark + tools on the first line, categories on the second */
.masthead-bar { border-bottom: 1px solid var(--ink); background: var(--paper); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 64px; }
.logo { display: block; color: var(--ink); flex: none; line-height: 0; }
.wordmark { display: block; height: 34px; width: auto; }
.lg-ink { fill: var(--ink); }
.lg-soft { fill: #4a4f5b; }
.lg-soft-stroke { stroke: #4a4f5b; }
.lg-fox { fill: var(--fox); }
.tools { display: flex; align-items: center; gap: 22px; flex: none; }
.tool { font-size: .84rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--text); padding: 6px 0; border-bottom: 2px solid transparent; white-space: nowrap; }
.tool:hover { color: var(--fox); }
.tool.active { color: var(--fox); border-bottom-color: var(--fox); }
.tool-ask { letter-spacing: .02em; text-transform: none; font-size: .95rem; color: #fff; background: var(--ink); border-radius: 4px; padding: 8px 16px; border-bottom: 0; }
.tool-ask:hover, .tool-ask.active { background: var(--fox); color: #fff; }
.catbar { border-top: 1px solid var(--rule); }
.cats { display: flex; flex-wrap: nowrap; overflow-x: auto; gap: 2px 26px; scrollbar-width: none; min-width: 0; }
.cats::-webkit-scrollbar { display: none; }
.cats a { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--text); padding: 11px 0 9px; border-bottom: 2px solid transparent; white-space: nowrap; }
.cats a:hover { color: var(--fox); }
.cats a.active { color: var(--fox); border-bottom-color: var(--fox); }
main { padding-top: 20px; padding-bottom: 64px; }
h1, h2, h3 { font-family: var(--serif); color: var(--ink); letter-spacing: -.015em; margin: 0; }

/* slim search line */
.searchbar { display: flex; gap: 8px; margin: 0 0 26px; padding-bottom: 16px; border-bottom: 1px solid var(--rule); }
.searchbar input[type="search"] { flex: 1 1 auto; min-width: 0; }
.searchbar select { flex: 0 0 210px; }
input[type="search"], select { font: inherit; font-size: .98rem; color: var(--ink); background: #fff; border: 1px solid var(--rule); border-radius: 4px; padding: 8px 12px; }
input:focus, select:focus { border-color: var(--ink); outline: none; }
button, .btn { display: inline-block; font: inherit; font-size: .98rem; font-weight: 700; background: var(--ink); color: #fff; border: 0; border-radius: 4px; padding: 8px 20px; cursor: pointer; white-space: nowrap; }
button:hover, .btn:hover { background: var(--fox); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--rule); }
.btn-ghost:hover { background: var(--fox-soft); color: var(--fox); }

/* article plate (only on the article page) */
.art { background: var(--plate); background-image: linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px); background-size: 16px 16px; aspect-ratio: 1 / 1; border-radius: 3px; }
.art svg { display: block; width: 100%; height: 100%; }
.a-ring circle { fill: none; stroke: var(--ac); stroke-opacity: .22; stroke-width: 1; vector-effect: non-scaling-stroke; }
.a-line path, .a-line circle { fill: none; stroke: var(--ac); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.cat-models { --ac: #ff8a4c; }
.cat-research { --ac: #4fd1b5; }
.cat-business { --ac: #f0c75e; }
.cat-chips { --ac: #a9b4c2; }
.cat-robotics { --ac: #c9a0f0; }
.cat-regulation { --ac: #dcd8cc; }
.cat-crypto_ai { --ac: #ff7b92; }
.cat-tools { --ac: #86df9a; }
.cat-other { --ac: #b9bccb; }

/* kicker, tags, meta */
.kicker { display: flex; align-items: center; gap: 12px; margin: 0 0 8px; }
.tag { font-size: .8rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--cc, var(--fox)); }
.tag:hover { text-decoration: underline; }
.card-meta { display: flex; align-items: center; gap: 14px; margin: 0; color: var(--muted); font-size: .95rem; }
.card-meta .more { margin-left: auto; font-weight: 700; color: var(--ink); }
.card h2 a, .card h3 a { background-image: linear-gradient(var(--cc, var(--fox)), var(--cc, var(--fox))); background-size: 0 2px; background-repeat: no-repeat; background-position: 0 100%; transition: background-size .2s ease; }
.card h2 a:hover, .card h3 a:hover { background-size: 100% 2px; }
.card .lead { margin: 0 0 12px; color: var(--text); }

/* front: lead story + rail (text only, full-width headlines) */
.front { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 0 48px; padding-bottom: 30px; margin-bottom: 30px; border-bottom: 1px solid var(--rule); }
.card.featured { padding-right: 48px; border-right: 1px solid var(--rule); }
.card.featured .card-text { border-top: 4px solid var(--cc, var(--fox)); padding-top: 18px; }
.card.featured h2 { font-size: 2.7rem; line-height: 1.08; font-weight: 700; margin-bottom: 16px; }
.card.featured .lead { font-size: 1.25rem; line-height: 1.55; color: #3a3e48; margin-bottom: 16px; }
.card.featured .card-meta { padding-top: 12px; border-top: 1px solid var(--rule-soft); }
.rail-title, .section-title { margin: 0 0 4px; font-family: var(--sans); font-size: .82rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--ink); padding-bottom: 8px; border-bottom: 2px solid var(--ink); }
.section-title .count { color: var(--muted); font-weight: 600; letter-spacing: 0; margin-left: 8px; }
.card.side { padding: 16px 0 18px; border-bottom: 1px solid var(--rule-soft); }
.card.side:last-child { border-bottom: 0; }
.card.side h2 { font-size: 1.28rem; line-height: 1.25; margin-bottom: 6px; font-weight: 700; }
.card.side .lead { font-size: .96rem; line-height: 1.5; margin-bottom: 8px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card.side .card-meta .more { display: none; }

/* feed: text rows with a coloured top rule, no pictures */
.feed { margin-bottom: 8px; }
.feed-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 36px; row-gap: 0; }
.card.row .card-text { border-top: 3px solid var(--cc, var(--rule)); padding: 14px 0 22px; margin-top: 22px; }
.card.row h2, .card.row h3 { font-size: 1.35rem; line-height: 1.25; margin-bottom: 8px; font-weight: 700; }
.card.row .lead { font-size: .98rem; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

.pager { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; margin: 40px 0 8px; }
.pg { min-width: 42px; text-align: center; padding: 8px 14px; border: 1px solid var(--rule); border-radius: 4px; background: #fff; color: var(--ink); font-weight: 700; }
.pg:hover { background: var(--fox-soft); }
.pg.current { background: var(--ink); color: #fff; border-color: var(--ink); }
.gap { color: var(--muted); }
.empty { border: 1px dashed var(--rule); padding: 56px 24px; text-align: center; background: #fff; }
.empty h2 { margin-bottom: 8px; }

/* article */
.crumbs { font-size: .95rem; color: var(--muted); margin-bottom: 20px; }
.crumbs span { margin: 0 6px; }
.crumbs a:hover { color: var(--fox); }
.story-head { max-width: 1072px; margin: 0 auto 30px; }
.story-head h1 { font-size: 3.3rem; line-height: 1.07; font-weight: 700; margin: 4px 0 20px; }
.deck { max-width: 820px; font-family: var(--serif); font-size: 1.38rem; line-height: 1.5; color: #3a3e48; margin: 0 0 22px; }
.byline { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 22px; margin: 0; padding: 12px 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule); color: var(--muted); font-size: 1rem; }
.byline strong { color: var(--ink); }
.story-grid { display: grid; grid-template-columns: minmax(0, 700px) 300px; gap: 0 72px; justify-content: center; align-items: start; }
.prose p { font-family: var(--serif); font-size: 1.22rem; line-height: 1.78; color: #20232a; margin: 0 0 1.25em; }
.why { margin: 36px 0 0; padding: 4px 0 4px 26px; border-left: 4px solid var(--fox); }
.why h2 { font-family: var(--sans); font-size: .85rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--fox); margin-bottom: 10px; }
.why p { font-size: 1.15rem; margin-bottom: .9em; }
.story-side { position: sticky; top: 24px; }
.source-box { border: 1px solid var(--ink); border-top: 4px solid var(--fox); padding: 20px 22px 22px; background: #fff; }
.source-label { margin: 0 0 4px; font-size: .78rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.source-name { margin: 0 0 10px; font-family: var(--serif); font-size: 1.3rem; font-weight: 700; color: var(--ink); line-height: 1.25; }
.attribution { margin: 0 0 16px; font-size: .98rem; color: var(--text); }
.source-link { display: block; text-align: center; background: var(--fox); color: #fff; font-weight: 800; font-size: 1.05rem; padding: 14px 16px; border-radius: 4px; }
.source-link:hover { background: var(--ink); }
.side-art { display: block; width: 120px; margin-top: 18px; }
.related { margin-top: 64px; }

.site-footer { background: var(--ink); color: #c9ccd6; padding: 30px 0 38px; font-size: .98rem; }
.site-footer p { margin: 0 0 4px; }
.site-footer strong { color: #fff; }
.site-footer .muted { color: #8e93a3; }
.foot-row { display: flex; gap: 32px; align-items: flex-start; }
.foot-logo { height: 28px; }
.foot-logo .lg-ink { fill: #fff; }
.foot-logo .lg-soft { fill: #c9ccd6; }
.foot-logo .lg-soft-stroke { stroke: #c9ccd6; }
.foot-brand { flex: none; line-height: 0; padding-top: 2px; }
.foot-links { margin-top: 10px !important; }
.foot-links a { margin-right: 22px; color: #fff; text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 1100px) {
  .feed-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1000px) {
  .front { grid-template-columns: 1fr; }
  .card.featured { padding-right: 0; border-right: 0; padding-bottom: 24px; margin-bottom: 8px; border-bottom: 1px solid var(--rule); }
  .story-grid { grid-template-columns: minmax(0, 700px); }
  .story-side { position: static; margin-top: 32px; }
  .story-head h1 { font-size: 2.7rem; }
  .card.featured h2 { font-size: 2.5rem; }
}
@media (max-width: 700px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  .bar { min-height: 54px; gap: 12px; }
  .wordmark { height: 24px; }
  .tools { gap: 10px; }
  .tool { font-size: .74rem; letter-spacing: .03em; }
  .tool-ask { font-size: .82rem; padding: 7px 10px; letter-spacing: 0; }
  .tool .long { display: none; }
  .cats { gap: 20px; -webkit-mask-image: linear-gradient(90deg, #000 88%, transparent); mask-image: linear-gradient(90deg, #000 88%, transparent); padding-right: 36px; }
  main { padding-top: 14px; }
  .searchbar { flex-wrap: wrap; margin-bottom: 20px; padding-bottom: 14px; }
  .searchbar input[type="search"] { flex: 1 1 0; min-width: 0; }
  .searchbar select { order: 3; flex: 1 1 100%; }
  .searchbar .btn { flex: 0 0 auto; }
  .searchbar .btn-ghost { order: 4; flex: 1 1 100%; text-align: center; }
  .feed-grid { grid-template-columns: 1fr; }
  .card.featured h2 { font-size: 1.95rem; }
  .card.featured .lead { font-size: 1.08rem; }
  .card.row h2, .card.row h3 { font-size: 1.25rem; }
  .story-head h1 { font-size: 2.05rem; }
  .deck { font-size: 1.16rem; }
  .prose p { font-size: 1.1rem; }
  .side-art { display: none; }
  .source-box { padding: 16px 18px 18px; }
}

/* v4 tuning: one-line category nav for many categories, balanced rail */
.rail:has(.card.side:nth-of-type(3)) .card.side + .card.side .lead { display: none; }
.card.featured .lead { font-size: 1.28rem; }
.when time { font-variant-numeric: tabular-nums; }
.byline .tz { font-size: .9rem; }

/* covers: optional original illustrations, always labelled */
.cover { margin: 0; }
.cover img { display: block; width: 100%; height: 100%; object-fit: cover; background: var(--rule-soft); }
.cover figcaption { margin-top: 8px; font-size: .86rem; color: var(--muted); }
.cover figcaption::before { content: ""; display: inline-block; width: 18px; height: 2px; background: var(--muted); vertical-align: middle; margin-right: 8px; }
.cover-large { margin-bottom: 20px; }
.cover-large a { display: block; aspect-ratio: 16 / 8; overflow: hidden; border-radius: 3px; }
.card.featured.has-cover .card-text { border-top: 0; padding-top: 0; }
.card.featured.has-cover .card-text .kicker { padding-top: 14px; border-top: 4px solid var(--cc, var(--fox)); }
.cover-wide { max-width: 1072px; margin: 0 auto 36px; }
.cover-wide a { display: block; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 3px; }
.cover-thumb { position: relative; display: block; width: 112px; aspect-ratio: 1 / 1; overflow: hidden; border-radius: 3px; flex: none; }
.cover-mark { position: absolute; left: 0; bottom: 0; padding: 2px 6px; font-size: .66rem; font-weight: 700; letter-spacing: .04em; color: #fff; background: rgba(21, 23, 28, .78); border-top-right-radius: 3px; }
.cover-thumb { float: right; margin: 4px 0 8px 18px; }
.card.has-cover .lead { clear: none; }
.card.side.has-cover .card-meta, .card.row.has-cover .card-meta { clear: both; }
@media (max-width: 700px) {
  .cover-large a { aspect-ratio: 16 / 9; }
  .cover-wide a { aspect-ratio: 16 / 9; }
  .cover-thumb { width: 84px; }
  .cover-thumb { margin-left: 14px; }
}
.kicker { flex-wrap: wrap; row-gap: 2px; }
.when { white-space: nowrap; }

.note-badge { display: inline-block; margin-left: 10px; padding: 1px 8px; border: 1px solid currentColor; border-radius: 999px; font-size: .72rem; font-weight: 700; letter-spacing: .04em; opacity: .75; }

.other-reports { margin: 4px 0 0; padding-left: 18px; font-size: .9rem; }
.other-reports li { margin: 2px 0; }

/* source links, source pages, about, chat */
.src { border-bottom: 1px solid var(--rule); }
.src:hover { color: var(--fox); border-bottom-color: var(--fox); }
.page-title { font-size: 2.6rem; line-height: 1.1; font-weight: 700; margin: 4px 0 12px; }
.page-lead { max-width: 820px; font-family: var(--serif); font-size: 1.22rem; line-height: 1.55; color: #3a3e48; margin: 0 0 28px; }
.org-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 36px; }
.org-card { border-top: 3px solid var(--rule); padding: 14px 0 22px; margin-top: 22px; }
.org-card h2 { font-size: 1.4rem; line-height: 1.2; margin-bottom: 6px; }
.org-card h2 a:hover { color: var(--fox); }
.org-meta { margin: 0 0 8px; color: var(--muted); font-size: .95rem; }
.org-kinds { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.org-kinds span, .org-inputs .kind { display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .03em; padding: 2px 9px; border: 1px solid var(--rule); border-radius: 999px; background: #fff; color: var(--text); }
.org-note { margin: 8px 0 0; font-size: .88rem; color: var(--muted); }
.org-head { margin-bottom: 8px; }
.org-inputs { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 6px; font-size: .95rem; color: var(--muted); }
.org-inputs strong { color: var(--ink); }
.org-inputs a { color: var(--fox); font-weight: 700; }
.prose-page { max-width: 760px; }
.prose-page h2 { font-size: 1.5rem; margin: 34px 0 8px; }
.prose-page p { font-family: var(--serif); font-size: 1.15rem; line-height: 1.75; color: #20232a; margin: 0 0 1em; }
.prose-page a { color: var(--fox); text-decoration: underline; text-underline-offset: 3px; }
.profile { display: grid; grid-template-columns: max-content 1fr; gap: 6px 22px; margin: 0; font-size: 1.05rem; }
.profile dt { color: var(--muted); }
.profile dd { margin: 0; color: var(--ink); }
.ask-page { max-width: 760px; }
.chat-box { margin-top: 44px; padding-top: 22px; border-top: 1px solid var(--rule); }
.chat-form { display: block; }
.chat-label { display: block; font-size: .85rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--ink); margin-bottom: 8px; }
.chat-row { display: flex; gap: 8px; }
.chat-row input[type="text"] { flex: 1 1 auto; min-width: 0; font: inherit; font-size: 1rem; color: var(--ink); background: #fff; border: 1px solid var(--rule); border-radius: 4px; padding: 10px 12px; }
.chat-row input:focus { border-color: var(--ink); outline: none; }
.chat-hint { margin: 12px 0 0; font-size: .88rem; color: var(--muted); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.answer { margin-top: 18px; padding: 16px 18px; background: #fff; border: 1px solid var(--rule); border-left: 4px solid var(--fox); border-radius: 3px; }
.answer p { margin: 0 0 8px; font-size: 1.05rem; line-height: 1.6; white-space: pre-line; }
.answer-unknown { border-left-color: var(--muted); }
.answer-error { border-left-color: #b3261e; }
.answer-src-title { font-size: .85rem !important; font-weight: 800; color: var(--muted); }
.answer ul { margin: 0; padding-left: 18px; }
.answer a { color: var(--fox); text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 1100px) { .org-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 700px) {
  .org-grid { grid-template-columns: 1fr; }
  .page-title { font-size: 2rem; }
  .page-lead { font-size: 1.1rem; }
  .prose-page p { font-size: 1.08rem; }
  .foot-row { flex-direction: column; gap: 14px; }
  .chat-row { flex-direction: column; }
  .profile { grid-template-columns: 1fr; gap: 0; }
  .profile dd { margin-bottom: 8px; }
}