/* Dark-first token set: a calm, technical "governed systems" console feel
   rather than a light SaaS page. Accent is a light blue chosen so it passes
   contrast both as link text on the dark page background and (inverted, via
   --accent-ink) as dark text on solid accent-filled buttons -- one accent
   color, two directions, both AA-safe, rather than juggling separate shades
   for light-on-dark vs. dark-on-light contrast. */
:root {
  --ink: #f3f7fb;
  --ink-soft: #a8b3c7;
  --paper: #0b1020;
  --paper-soft: #172033;
  --border: #293449;
  --accent: #60a5fa;
  --accent-hover: #93c5fd;
  --accent-ink: #0b1020;
  --nav-bg: #05070d;
  --radius: 10px;
  --max-width: 880px;
  --good: #34d399;
  --good-ink: #0b1020;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
  /* Defensive: nothing below should force horizontal scroll at any viewport
     width (checked down to 320px), but this is a last-resort guard since a
     future edit is a bigger risk than this rule masking a real bug here. */
  overflow-x: hidden;
}

/* Global link color -- without this, inline prose links (anything not
   inside a card/nav/footer selector with its own color rule) fall back to
   the browser's default blue, which reads as unstyled/low-contrast against
   the dark background. */
a {
  color: var(--accent);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--accent-hover, var(--accent));
}

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Spacing after card grids so trailing CTA paragraphs don't crash into the
   card above them. */
.project-grid + p,
.project-grid + .section-cta,
.project-grid + .section-note,
.snapshot-list + p,
.snapshot-list + .section-note,
.cert-list + p,
.cert-list + .section-note {
  margin-top: clamp(1.5rem, 4vw, 2.5rem);
}

@media (max-width: 640px) {
  .project-grid + p,
  .project-grid + .section-cta,
  .project-grid + .section-note {
    margin-top: 1.75rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

.ticker {
  background: var(--nav-bg);
  border-bottom: 1px solid rgba(47, 95, 218, 0.4);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 24px;
  overflow: hidden;
}

.ticker-label {
  flex-shrink: 0;
  color: var(--accent);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ticker-viewport {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  mask-image: linear-gradient(to right, transparent, black 24px, black calc(100% - 24px), transparent);
}

.ticker-track {
  display: inline-flex;
  gap: 32px;
  color: #d7dae0;
  font-size: 0.85rem;
}

.ticker-track.ticker-track-animated {
  animation: ticker-scroll 45s linear infinite;
}

.ticker:hover .ticker-track.ticker-track-animated,
.ticker:focus-within .ticker-track.ticker-track-animated {
  animation-play-state: paused;
}

.ticker-track a {
  color: #d7dae0;
  text-decoration: none;
}

.ticker-track a:hover,
.ticker-track a:focus-visible {
  color: #ffffff;
  text-decoration: underline;
}

.ticker-sep {
  color: #4a4f58;
}

@keyframes ticker-scroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  /* A frozen mid-scroll frame is worse than no animation at all: show every
     headline as a normal wrapped, readable list instead. */
  .ticker-viewport {
    overflow: visible;
    mask-image: none;
  }
  .ticker-track {
    display: flex;
    flex-wrap: wrap;
    white-space: normal;
    animation: none !important;
  }
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.hero {
  position: relative;
  background: var(--paper-soft);
  border-bottom: 1px solid var(--border);
  padding: 64px 0 40px;
  overflow: hidden;
  isolation: isolate;
}

/* Soft layered radial-glow backdrop, adapted from a technique common on
   premium marketing sites: two large soft blobs plus a blurred duplicate
   layer, pure CSS, no images/animation -- purely a static depth cue. */
.hero::before {
  content: "";
  position: absolute;
  inset: -20%;
  z-index: -1;
  background:
    radial-gradient(60% 60% at 12% 15%, rgba(96, 165, 250, 0.20), transparent 70%),
    radial-gradient(50% 50% at 88% 25%, rgba(45, 212, 191, 0.14), transparent 70%);
  filter: blur(30px);
  pointer-events: none;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 32px;
  align-items: center;
}

.hero-media {
  min-width: 0;
}

.hero-media-frame {
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: linear-gradient(160deg, var(--paper) 0%, var(--paper-soft) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  text-align: center;
}

.hero-media-note {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.85rem;
}

@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-media {
    order: 2;
  }

  .hero-media-frame {
    aspect-ratio: 16 / 9;
    max-height: 220px;
  }
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink-soft);
  margin: 0 0 8px;
}

.hero h1 {
  margin: 0 0 8px;
  font-size: clamp(2rem, 4vw, 2.75rem);
}

.subhead {
  margin: 0 0 4px;
  font-size: 1.15rem;
  color: var(--ink-soft);
}

.location {
  margin: 0 0 20px;
  color: var(--ink-soft);
}

.links a {
  display: inline-block;
  margin-right: 16px;
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.links a:hover {
  text-decoration: underline;
}

.links .cta {
  background: var(--accent);
  color: var(--accent-ink);
  padding: 8px 16px;
  border-radius: var(--radius);
}

.links .cta:hover {
  text-decoration: none;
  opacity: 0.9;
}

.links .cta-secondary {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}

/* Mobile hero CTA alignment: clean vertical stack for primary CTAs,
   equal two-column for LinkedIn/GitLab on narrow viewports. */
@media (max-width: 640px) {
  .links {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .links .hero-social-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .links .hero-social-actions a {
    margin-right: 0;
    text-align: center;
  }
}

/* Desktop keeps the original inline layout for social links. */
@media (min-width: 641px) {
  .links .hero-social-actions {
    display: inline;
  }
  .links .hero-social-actions a {
    margin-right: 16px;
  }
}

main section {
  padding: 40px 0;
  border-bottom: 1px solid var(--border);
}

main section:last-of-type {
  border-bottom: none;
}

h2 {
  font-size: 1.5rem;
  margin: 0 0 20px;
}

.section-note {
  color: var(--ink-soft);
  margin-top: -8px;
  margin-bottom: 20px;
}

.role {
  margin-bottom: 28px;
}

.role h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.role ul {
  margin: 0;
  padding-left: 20px;
}

.role li {
  margin-bottom: 6px;
}

.role-ref {
  margin: 8px 0 0;
  font-size: 0.85rem;
  color: var(--ink-soft);
}

.role-ref a {
  color: var(--accent);
  text-decoration: none;
}

.role-ref a:hover {
  text-decoration: underline;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

/* Public Reference Projects and Use-Case Labs each have exactly 4 cards --
   scoped to these two sections only (by id) so unrelated grids that don't
   have exactly 4 items keep the general auto-fit behavior above. */
@media (min-width: 640px) and (max-width: 899px) {
  #projects .project-grid,
  #labs .project-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 900px) {
  #projects .project-grid,
  #labs .project-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.project-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  background: var(--paper-soft);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.project-card:hover,
.signal-card:hover {
  transform: translateY(-4px);
  border-color: rgba(96, 165, 250, 0.4);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.28);
}

@media (prefers-reduced-motion: reduce) {
  .project-card,
  .signal-card {
    transition: none;
  }

  .project-card:hover,
  .signal-card:hover {
    transform: none;
  }
}

.project-card h3,
.project-card h4 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.project-card p {
  color: var(--ink-soft);
  margin: 0 0 12px;
}

.project-card a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.project-card a:hover {
  text-decoration: underline;
}

.cert-list {
  padding-left: 20px;
  margin: 0;
}

.cert-list li {
  margin-bottom: 6px;
}

#chat-form {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

#chat-question {
  flex: 1;
  min-width: 0;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 1rem;
}

#chat-form button {
  padding: 10px 20px;
  border: none;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  cursor: pointer;
}

#chat-form button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

#chat-status {
  color: var(--ink-soft);
  min-height: 1.4em;
  margin-bottom: 8px;
}

#chat-answer {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  background: var(--paper-soft);
  overflow-wrap: anywhere;
}

#chat-answer.degraded {
  border-color: #d98e04;
  background: #2a1f08;
}

.evidence-list {
  margin: 12px 0 0;
  padding-left: 20px;
  font-size: 0.85rem;
  color: var(--ink-soft);
}

.coverage-badge {
  display: inline-block;
  margin: 4px 0 0;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: var(--paper);
  border: 1px solid var(--border);
  color: var(--ink-soft);
}

.chat-metadata-strip {
  margin: 8px 0 0;
  font-size: 0.78rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--ink-soft);
}

details#chat-sources,
details#floating-chat-sources {
  margin-top: 8px;
}

details#chat-sources summary,
details#floating-chat-sources summary {
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--accent);
  font-weight: 600;
}

.architecture-diagram-frame {
  position: relative;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: linear-gradient(165deg, var(--paper-soft) 0%, var(--paper) 100%);
  padding: 20px;
  overflow: hidden;
  isolation: isolate;
}

.architecture-diagram-frame::before {
  content: "";
  position: absolute;
  inset: -30%;
  z-index: -1;
  background: radial-gradient(50% 50% at 20% 20%, rgba(96, 165, 250, 0.14), transparent 70%);
  filter: blur(24px);
  pointer-events: none;
}

.architecture-diagram {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
}

footer {
  padding: 32px 0 48px;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.footer-note {
  margin-top: 4px;
  font-size: 0.8rem;
  color: var(--ink-soft);
  opacity: 0.85;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 8px;
  top: -48px;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 10px 16px;
  border-radius: var(--radius);
  z-index: 100;
  transition: top 0.1s ease-in-out;
  text-decoration: none;
  font-weight: 600;
}

.skip-link:focus {
  top: 8px;
}

.site-nav {
  background: var(--nav-bg);
  border-bottom: 1px solid var(--border);
}

.site-nav-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 20px;
  padding: 12px 24px;
}

.site-nav a {
  color: #fff;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  opacity: 0.85;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  opacity: 1;
  text-decoration: underline;
}

/* Desktop/tablet: the menu's links are plain flex siblings in the same row
   as Home -- `display: contents` means this wrapper contributes no box of
   its own, so today's horizontal layout is unchanged. Mobile-only styles
   below turn it into a real collapsible panel. */
.site-nav-menu {
  display: contents;
}

.nav-toggle {
  display: none;
}

@media (max-width: 720px) {
  .site-nav-inner {
    justify-content: space-between;
    position: relative;
  }

  .nav-toggle {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: transparent;
    cursor: pointer;
    order: 2;
  }

  .nav-toggle-bar {
    display: block;
    width: 16px;
    height: 2px;
    margin: 0 auto;
    background: #fff;
  }

  .language-toggle {
    order: 1;
    margin-left: 0;
  }

  .site-nav-menu {
    display: none;
    order: 3;
    flex-basis: 100%;
    flex-direction: column;
    gap: 2px;
    padding-top: 10px;
    margin-top: 10px;
    border-top: 1px solid var(--border);
    max-width: calc(100vw - 48px);
  }

  .site-nav-menu.is-open {
    display: flex;
  }

  .site-nav-menu a {
    padding: 8px 4px;
  }
}

.language-toggle {
  display: inline-flex;
  gap: 4px;
  margin-left: auto;
}

.language-toggle-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: #fff;
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  opacity: 0.8;
}

.language-toggle-btn.active,
.language-toggle-btn:hover,
.language-toggle-btn:focus-visible {
  opacity: 1;
  border-color: var(--accent);
}

.language-toggle-flag {
  display: inline-flex;
  align-items: center;
  vertical-align: -1px;
}

.language-toggle-flag svg {
  display: inline-block;
  width: 14px;
  height: 10px;
  flex: 0 0 auto;
}

.snapshot-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 0 0 16px;
}

.snapshot-list > div {
  border: 1px solid #ded5c1;
  border-radius: var(--radius);
  padding: 16px;
  /* Cream card on an otherwise dark page: the highest-contrast option for
     dense label/value fact boxes, so this specific block gets its own
     light-on-dark-page treatment rather than reusing --paper/--ink. */
  background: #f5f1e6;
}

.snapshot-list dt {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #6b6455;
  margin-bottom: 4px;
}

.snapshot-list dd {
  margin: 0;
  font-weight: 600;
  color: #1c1a15;
}

.suggested-questions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.chip {
  border: 1px solid var(--border);
  background: var(--paper-soft);
  color: var(--ink);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.85rem;
  cursor: pointer;
}

.chip:hover {
  background: var(--border);
}

.signal-card {
  border-radius: 14px;
  padding: 18px 20px 16px;
  background: linear-gradient(165deg, var(--paper-soft) 0%, var(--paper) 100%);
}

.signal-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 4px;
}

.signal-card-header h3 {
  margin: 0;
  font-size: 1rem;
}

.signal-badge {
  display: inline-block;
  flex-shrink: 0;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border: 1px solid var(--border);
  color: var(--ink-soft);
  background: var(--paper);
}

.signal-detail-list {
  display: grid;
  gap: 2px;
  margin: 12px 0 10px;
  padding: 0;
  list-style: none;
}

.signal-detail-list li {
  display: grid;
  grid-template-columns: minmax(92px, 0.42fr) 1fr;
  gap: 12px;
  padding: 6px 0;
}

.signal-detail-list li + li {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.signal-row-label {
  color: var(--ink-soft);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.signal-card-meta {
  margin: 8px 0 0;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  color: var(--ink-soft);
  font-size: 0.78rem;
}

.status-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0;
  padding: 0;
  list-style: none;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--border);
  background: var(--paper);
  color: var(--ink);
  border-radius: 999px;
  padding: 6px 12px 6px 8px;
  font-size: 0.8rem;
  margin: 0 0 10px;
}

.status-chip .status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--good);
  flex-shrink: 0;
}

.status-chip .status-tag {
  color: var(--ink-soft);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.diagram-boundary-label {
  fill: var(--ink-soft);
  font-size: 11px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.signal-badge-ok {
  color: #4ade80;
  border-color: #2f6b45;
  background: #12261a;
}

.signal-badge-degraded,
.signal-badge-unavailable {
  color: #fbbf24;
  border-color: #6b5215;
  background: #26200f;
}

.signal-badge-experimental {
  color: var(--ink-soft);
}

.lab-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin: 0 0 24px;
}

.lab-meta > div {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  background: var(--paper-soft);
}

.lab-meta h3 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.table-scroll {
  overflow-x: auto;
  margin: 12px 0 24px;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
}

.data-table caption {
  text-align: left;
  font-weight: 600;
  margin-bottom: 8px;
}

.data-table th,
.data-table td {
  border: 1px solid var(--border);
  padding: 8px 10px;
  text-align: left;
  font-size: 0.9rem;
}

.data-table th {
  background: var(--paper-soft);
}

.claim-boundary {
  border-left: 3px solid var(--accent);
  padding: 4px 0 4px 16px;
  margin: 16px 0;
  color: var(--ink-soft);
}

/* Floating evidence-backed chat launcher + panel (only mounted when /chat/status reports available) */
.chat-launcher {
  position: fixed;
  right: 16px;
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 1000;
  padding: 12px 18px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  font-size: 0.95rem;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
  cursor: pointer;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}
.chat-launcher:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
}
@media (prefers-reduced-motion: reduce) {
  .chat-launcher { transition: none; }
}

.chat-panel {
  position: fixed;
  right: 16px;
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 1001;
  width: min(380px, calc(100vw - 32px));
  max-height: calc(100dvh - 40px - env(safe-area-inset-bottom));
  background: var(--paper-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.chat-panel-inner {
  display: flex;
  flex-direction: column;
  padding: 14px 16px 16px;
  gap: 8px;
  max-height: inherit;
  overflow: auto;
}
.chat-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2px;
}
.chat-panel-header h2 {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
}
.chat-close {
  background: transparent;
  border: none;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  color: var(--ink-soft);
  padding: 2px 6px;
}
.chat-subhead {
  margin: 0 0 6px;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.chat-input-row {
  display: flex;
  gap: 8px;
}
.chat-input-row input {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.95rem;
}
.chat-input-row button {
  padding: 10px 16px;
  border: none;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  cursor: pointer;
}
.chat-input-row button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
#floating-chat-status {
  min-height: 1.2em;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.chat-thread {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.chat-turn {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.chat-turn-question {
  align-self: flex-end;
  max-width: 90%;
  margin: 0;
  padding: 8px 12px;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  overflow-wrap: anywhere;
}
.chat-answer {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  background: var(--paper-soft);
  margin-top: 4px;
  overflow-wrap: anywhere;
}
.chat-answer.degraded {
  border-color: #d98e04;
  background: #2a1f08;
}

.proof-pack-share {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 12px 0 20px;
}

.proof-pack-share #proof-pack-copy-status {
  min-height: 1.2em;
}

.proof-pack-artifact-card p {
  min-height: 2.6em;
}

@media (max-width: 640px) {
  body {
    padding-bottom: calc(96px + env(safe-area-inset-bottom));
  }

  .project-card {
    padding: 16px;
  }

  .project-card h3,
  .project-card h4 {
    font-size: 1rem;
  }

  .project-card p {
    font-size: 0.92rem;
  }

  .chat-launcher {
    /* Compact circular icon on mobile -- the full "Ask Nkosi's portfolio"
       pill is wide enough to sit on top of card text/CTAs on narrow
       viewports. Text stays for screen readers via aria-label; visually
       it's replaced by a chat-bubble icon. */
    right: 16px;
    bottom: calc(env(safe-area-inset-bottom) + 24px);
    max-width: calc(100vw - 24px);
    width: 52px;
    height: 52px;
    max-width: none;
    padding: 0;
    border-radius: 50%;
    font-size: 0;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .chat-launcher::before {
    content: "\1F4AC";
    font-size: 1.4rem;
  }

  .chat-panel {
    right: 12px;
    bottom: max(20px, env(safe-area-inset-bottom));
    width: min(380px, calc(100vw - 24px));
    max-height: calc(100dvh - 40px - env(safe-area-inset-bottom));
  }
}

@media print {
  .site-nav,
  .ticker,
  .chat-launcher,
  .chat-panel,
  .skip-link,
  #proof-pack-copy-status {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
  }

  a {
    color: #000;
    text-decoration: underline;
  }

  .project-card,
  .status-chip {
    border-color: #999;
    background: transparent;
    color: #000;
  }
}

.recruiter-snapshot-list {
  color: var(--ink-soft);
  margin: 8px 0 16px;
  padding-left: 20px;
}

.recruiter-snapshot-list li {
  margin-bottom: 10px;
  line-height: 1.5;
}

.recruiter-snapshot-list strong {
  color: var(--ink);
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
  padding: 0;
  list-style: none;
}

a.pill {
  text-decoration: none;
}

a.pill:hover,
a.pill:focus-visible {
  border-color: var(--accent);
  text-decoration: none;
}

.capability-inspect-label {
  margin-bottom: 4px;
}

.pill {
  display: inline-block;
  border: 1px solid var(--border);
  background: var(--paper-soft);
  color: var(--ink);
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 0.8rem;
}

/* Prevent iOS/Safari from styling date ranges inside pills as blue links.
   Keep the pill itself tappable if it ever becomes a link, but the date text
   must never render as an underlined link. */
.cert-date,
.cert-date a,
.pill .cert-date {
  color: inherit;
  text-decoration: none;
  pointer-events: none;
  -webkit-touch-callout: none;
}

.compact-callout {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  background: var(--paper-soft);
  margin: 12px 0;
}

.compact-callout p {
  margin: 4px 0;
}

/* Deterministic Ingestion section (H2 AISP-style proof) */
.how-i-work {
  margin: 0 0 16px;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.flow-diagram {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 12px 0;
  padding: 10px;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: var(--paper);
  font-size: 0.9rem;
  color: var(--ink-soft);
}

.flow-step {
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--paper-soft);
}

.flow-arrow {
  color: var(--accent);
  font-weight: 600;
}

.before-after {
  margin: 10px 0 14px;
  padding: 10px 12px;
  border-left: 3px solid var(--accent);
  background: var(--paper-soft);
  font-size: 0.9rem;
}

.repo-list {
  margin: 8px 0 16px;
  padding-left: 20px;
}

.repo-list li {
  margin-bottom: 6px;
  color: var(--ink-soft);
}

.repo-list a {
  color: var(--accent);
  font-weight: 600;
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 420ms cubic-bezier(0.22, 1, 0.36, 1), transform 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
