/* c.pages.css — multi-page component styles (nav-active, page
   heads, previews, cases, process, manifest, trust). Loaded after
   c.css, before c.mobile.css — preserves the original cascade. */
/* ============================================================
   MULTI-PAGE SITE — nav active, page heads, previews, cases
   ============================================================ */

/* active nav */
.c-navlinks a { position: relative; }
.c-navlinks a.is-active { color: var(--blue); }
.c-navlinks a.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -7px; height: 2px; background: var(--blue); }
.c-logo { cursor: pointer; }

/* editorial page header (dedicated pages) */
.c-page-head { padding: 60px var(--pad-x) 44px; border-bottom: 1px solid var(--line); position: relative; background-image: linear-gradient(var(--line-2) 1px, transparent 1px), linear-gradient(90deg, var(--line-2) 1px, transparent 1px); background-size: 56px 56px; }
.c-page-meta { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-bottom: 24px; margin-bottom: 34px; border-bottom: 1px solid var(--line-2); }
.c-page-meta .c-lbl, .c-page-meta .sh-r { white-space: nowrap; }
.c-page-title { font-family: "Space Grotesk",sans-serif; font-weight: 600; font-size: clamp(34px, 3.8vw, 60px); letter-spacing: -.032em; line-height: 1.04; max-width: 20ch; }
.c-page-intro { margin-top: 22px; font-size: 18px; line-height: 1.62; color: var(--ink-2); max-width: 58ch; }

/* projects (Work) */
.c-cases { }
.c-case { display: grid; grid-template-columns: 1.05fr 1fr; border-top: 1px solid var(--line); }
.c-case:first-child { border-top: 0; }
.c-case-l { padding: var(--pad-x); border-right: 1px solid var(--line); }
.c-case.flip .c-case-l { border-right: 0; }
.c-case.flip .c-case-r { border-right: 1px solid var(--line); }
@media (min-width: 981px) { .c-case.flip .c-case-l { order: 2; } .c-case.flip .c-case-r { order: 1; } }
.c-case-meta { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.c-status { font-family: "IBM Plex Mono",monospace; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2); display: inline-flex; align-items: center; gap: 9px; }
.c-status::before { content: ""; width: 7px; height: 7px; background: var(--blue); flex: none; }
.c-case-l .wt { display: flex; gap: 8px; }
.c-case-l :is(h2,h3) { font-size: 32px; margin-top: 20px; letter-spacing: -.025em; }
.c-case-l .ws { margin-top: 16px; font-size: 15.5px; color: var(--ink-2); line-height: 1.6; max-width: 44ch; }
.c-case-l .c-wtags { margin-top: 24px; display: flex; gap: 8px; flex-wrap: wrap; }
.c-case-r { padding: var(--pad-x); background: var(--bg); display: flex; align-items: center; background-image: linear-gradient(var(--line-2) 1px, transparent 1px), linear-gradient(90deg, var(--line-2) 1px, transparent 1px); background-size: 40px 40px; }

/* manifest spec visual */
.c-manifest { width: 100%; background: var(--paper); border: 1px solid var(--ink); }
.c-manifest-h { padding: 14px 18px; border-bottom: 1px solid var(--line); font-family: "IBM Plex Mono",monospace; font-size: 12.5px; letter-spacing: .04em; display: flex; align-items: center; justify-content: space-between; }
.c-manifest-h .tr { color: var(--blue); }
.c-manifest-b { padding: 4px 18px 18px; }
.c-mrow { display: flex; align-items: baseline; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line-2); }
.c-mrow .mn { font-family: "Space Grotesk",sans-serif; font-weight: 600; font-size: 30px; color: var(--blue); letter-spacing: -.02em; min-width: 2.5ch; }
.c-mrow .mt { font-family: "IBM Plex Mono",monospace; font-size: 12.5px; color: var(--ink-2); letter-spacing: .02em; }
.c-mstack { padding-top: 16px; display: flex; flex-wrap: wrap; gap: 8px; }
.c-mstack span { font-family: "IBM Plex Mono",monospace; font-size: 12px; padding: 5px 11px; border: 1px solid var(--line); color: var(--ink-2); letter-spacing: .02em; }

/* contact CTA band (previews + page bottoms) */
.c-cta-band { padding: 64px var(--pad-x); max-width: 760px; }
.c-cta-band h2 { font-family: "Space Grotesk",sans-serif; font-weight: 600; font-size: 42px; margin-top: 16px; letter-spacing: -.03em; line-height: 1.05; }
.c-cta-band h2 .ac { color: var(--blue); }
.c-cta-intro.big { margin-top: 0; font-size: 18px; max-width: 46ch; }
.c-cta.as-page .c-cta-l { display: flex; flex-direction: column; justify-content: center; }

/* ============================================================
   TOPIC CARDS — Writing page. One card per series with pages. A
   card is a hash link that writing-filter.js turns into a filter
   on the feed below. It borrows the service card's look (c.css
   card): hairline box, blue top rule drawn on hover. The rule
   and the blue border stay on while the card is the active filter
   (aria-current), so the state needs no extra class.
   ============================================================ */
.c-topics {
  display: grid;
  /* auto-fit: two cards fill the row as well as three do, which
     matters while a series has no page yet and so no card. */
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  padding: 40px var(--pad-x);
  border-bottom: 1px solid var(--line);
}
.c-topic {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 26px 26px 20px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: inherit;
  text-decoration: none;
  transition: border-color .2s ease, transform .28s ease,
              box-shadow .28s ease;
}
.c-topic::before {
  content: "";
  position: absolute;
  left: -1px; right: -1px; top: -1px;
  height: 2px;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .4s cubic-bezier(.2,.7,.2,1);
}
.c-topic:hover {
  border-color: #C7C8CE;
  transform: translateY(-4px);
  box-shadow: 0 18px 38px -28px rgba(10,10,11,.45);
}
.c-topic:hover::before,
.c-topic[aria-current]::before { transform: scaleX(1); }
.c-topic[aria-current] { border-color: var(--blue); }
.c-topic-k, .c-topic-foot {
  font-family: "IBM Plex Mono", monospace;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}
.c-topic-t {
  margin-top: 22px;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 22px;
  letter-spacing: -.02em;
  line-height: 1.2;
  transition: color .2s ease;
}
.c-topic:hover .c-topic-t,
.c-topic[aria-current] .c-topic-t { color: var(--blue); }
.c-topic-b {
  margin: 10px 0 20px;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--ink-2);
}
.c-topic-foot {
  display: flex;
  gap: 10px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.c-topic-n { margin-left: auto; color: var(--ink); }
/* The foot reads "Published 5" until the card is the active
   filter, then "Show all 5": a second click clears the filter. */
.c-topic-x { display: none; color: var(--blue); }
.c-topic[aria-current] .c-topic-x { display: inline; }
.c-topic[aria-current] .c-topic-l { display: none; }
/* .c-post is a grid, which would override the hidden attribute
   the filter sets on rows of the other series. */
.c-post[hidden] { display: none; }
