/* ─── Reset ───────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ─── Accessibility ────────────────────────────────────────────────────────── */
.skip-nav {
  position: absolute;
  top: -10rem;
  left: 0;
  background: var(--ink, #0e0e0e);
  color: #fff;
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  z-index: 9999;
  text-decoration: none;
}
.skip-nav:focus { top: 0; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ─── Design Tokens — Paper Palette ──────────────────────────────────────── */
:root {
  /* Colours */
  --ink:        #0e0e0e;
  --ink-2:      #3a3a3a;
  --ink-3:      #595959;
  --paper:      #f5f2eb;
  --paper-2:    #ede9df;
  --paper-3:    #e4dfd3;
  --accent:     #c8410a;
  --accent-2:   #f0dcd2;
  --green:      #1a6644;
  --green-bg:   #daf0e6;
  --blue-bg:    #dceaf5;
  --blue:       #1a4a80;
  --rule:       #c8c2b4;

  /* Legacy aliases — keep pages that reference old token names working */
  --bg:             var(--paper);
  --bg-card:        var(--paper-2);
  --bg-hover:       var(--paper-3);
  --bg-alt:         var(--paper-2);
  --border:         var(--rule);
  --text:           var(--ink);
  --text-dim:       var(--ink-2);
  --text-head:      var(--ink);
  --accent-dim:     var(--accent-2);
  --accent-hover:   #a83508;
  --danger:         #c0392b;
  --link:           var(--accent);
  --shadow-sm:      0 1px 3px rgba(14,14,14,0.06), 0 1px 2px rgba(14,14,14,0.04);
  --shadow:         0 4px 12px rgba(14,14,14,0.08), 0 2px 4px rgba(14,14,14,0.04);
  --shadow-lg:      0 10px 28px rgba(14,14,14,0.10), 0 4px 8px rgba(14,14,14,0.05);

  /* Typography */
  --font-sans:  'Outfit', system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Arial, sans-serif;
  --font-mono:  'DM Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, 'Liberation Mono', monospace;
  --font:       var(--font-sans);
  /* Legacy aliases — existing var(--sans) / var(--serif) / var(--mono) kept working */
  --sans:       var(--font-sans);
  --serif:      var(--font-sans);
  --mono:       var(--font-mono);

  /* Geometry */
  --radius:         0;
  --radius-sm:      3px;
  --radius-pill:    999px;
  --max-w:          1100px;

  /* Article / component aliases */
  --surface:        var(--paper-2);
  --text-body:      var(--ink);
}

/* ─── Base ────────────────────────────────────────────────────────────────── */
html { font-size: 16px; scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ─── Focus ───────────────────────────────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ─── Typography ─────────────────────────────────────────────────────────── */
h1, h2, h3, h4 {
  color: var(--ink);
  line-height: 1.2;
  font-family: var(--font-sans);
}
h1 { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 700; letter-spacing: -0.03em; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 600; letter-spacing: -0.02em; margin-bottom: 1.25rem; }
h3 { font-size: 1.05rem; font-weight: 600; letter-spacing: -0.02em; margin-bottom: 0.5rem; }
p  { margin-bottom: 1rem; }
a  { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

code, kbd {
  font-family: var(--mono);
  font-size: 0.85em;
}

.accent { color: var(--accent); }

/* ─── Layout ─────────────────────────────────────────────────────────────── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}
.container.narrow { max-width: 640px; }

.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; }

section { padding: 5rem 0; }

/* ─── Navigation ─────────────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  height: 56px;
}

/* Logo */
.logo {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
}
.logo .accent,
.logo span { color: var(--accent); }
.logo:hover { text-decoration: none; }

/* Wordmark (same treatment as .logo; used by migrated article pages) */
.site-logo {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
}
.site-logo span { color: var(--accent); }
.site-logo:hover { text-decoration: none; }

.site-header .container {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

/* Nav links */
.site-nav {
  display: flex;
  align-items: center;
  gap: 0;
}
.site-nav a {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--ink-2);
  text-decoration: none;
  padding: 0 14px;
  height: 56px;
  display: flex;
  align-items: center;
  border-left: 1px solid var(--rule);
  transition: color 0.15s, background 0.15s;
}
.site-nav a:hover {
  color: var(--ink);
  background: var(--paper-2);
  text-decoration: none;
}
.site-nav a.active,
.site-nav a[aria-current="page"] {
  color: var(--ink);
  background: var(--paper-2);
}
.site-nav a.primary {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.site-nav a.primary:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* ─── Hero ───────────────────────────────────────────────────────────────── */
.hero {
  padding: 5rem 0 4rem;
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}

.hero-sm { padding: 3rem 0 2.5rem; border-bottom: 1px solid var(--rule); }

.hero-sub {
  font-size: 1.1rem;
  color: var(--ink-2);
  max-width: 600px;
  margin: 1.25rem 0 2rem;
  line-height: 1.7;
  font-weight: 400;
}

.hero-cta { display: flex; gap: 0.75rem; flex-wrap: wrap; align-items: center; }

.hero-text-cta {
  font-family: var(--mono);
  font-size: 0.875rem;
  color: var(--ink-3);
  text-decoration: none;
  transition: color 0.15s;
}
.hero-text-cta:hover { color: var(--accent); text-decoration: none; }

.hero-stack {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--ink-3);
  letter-spacing: 0.04em;
  margin-top: 1.5rem;
}

/* ─── Buttons ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-block;
  padding: 0.75rem 1.6rem;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  text-decoration: none;
  line-height: 1;
  border: none;
}

.btn-primary {
  background: var(--ink);
  color: var(--paper);
  border: 1px solid var(--ink);
}
.btn-primary:hover {
  background: var(--accent);
  border-color: var(--accent);
  text-decoration: none;
  color: #fff;
}
.btn-primary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.btn-secondary {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--rule);
}
.btn-secondary:hover {
  border-color: var(--ink);
  color: var(--ink);
  text-decoration: none;
  background: var(--paper-2);
}

/* ─── Feature Cards ──────────────────────────────────────────────────────── */
.features {
  background: var(--paper-2);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.feature-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 1.75rem;
  transition: background 0.15s;
}
.feature-card:hover { background: var(--paper-2); }
.feature-card h3 {
  font-family: var(--serif);
  font-size: 1.1rem;
  font-weight: 300;
  margin-bottom: 0.6rem;
}
.feature-card p { font-size: 14px; color: var(--ink-2); line-height: 1.65; }
.feature-card a { font-size: 0.85rem; color: var(--accent); }

.feature-icon {
  font-family: var(--mono);
  font-size: 1.25rem;
  color: var(--accent);
  margin-bottom: 1rem;
  display: block;
}
/* SVG feature icon variant */
.feature-icon svg {
  width: 36px;
  height: 36px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ─── Tool Cards ─────────────────────────────────────────────────────────── */
.tool-card {
  display: block;
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 1.75rem;
  color: var(--ink);
  text-decoration: none;
  transition: background 0.15s;
}
.tool-card:hover { background: var(--paper-2); text-decoration: none; }
.tool-card h3 {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 300;
  color: var(--ink);
  margin-bottom: 0.5rem;
}
.tool-card p { font-size: 14px; color: var(--ink-2); line-height: 1.6; }

.tool-tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

/* ─── Category Tag ───────────────────────────────────────────────────────── */
.cat-tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-2);
  border: 1px solid var(--rule);
  padding: 0.15rem 0.45rem;
  vertical-align: middle;
  line-height: 1.4;
  flex-shrink: 0;
}

/* ─── Article Cards ──────────────────────────────────────────────────────── */
.article-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}

.article-card {
  display: block;
  background: var(--paper);
  padding: 1.5rem;
  color: var(--ink);
  text-decoration: none;
  transition: background 0.15s;
}
.article-card:hover { background: var(--paper-2); text-decoration: none; }
.article-card h3 {
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 300;
  color: var(--ink);
  margin: 0.5rem 0 0.5rem;
}
.article-card p { font-size: 0.875rem; color: var(--ink-2); margin: 0; }

.article-tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  color: var(--accent);
  background: var(--accent-2);
}

/* ─── Newsletter ─────────────────────────────────────────────────────────── */
.newsletter-section {
  background: var(--ink);
  color: var(--paper);
  padding: 3rem 0;
}

.newsletter-form {
  display: flex;
  gap: 0;
  flex-wrap: nowrap;
  margin: 1.5rem 0 1rem;
}

.newsletter-form input[type="email"] {
  flex: 1 1 240px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.2);
  border-right: none;
  color: var(--paper);
  font-family: var(--mono);
  font-size: 13px;
  padding: 14px 16px;
  outline: none;
}
.newsletter-form input[type="email"]:focus {
  border-color: rgba(255,255,255,0.5);
  background: rgba(255,255,255,0.12);
}
.newsletter-form input[type="email"]::placeholder { color: #666; }

.newsletter-form .btn-primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  white-space: nowrap;
}
.newsletter-form .btn-primary:hover { background: #a83508; border-color: #a83508; }

.privacy-notice { font-size: 0.8rem; color: var(--ink-3); font-family: var(--mono); }
.privacy-notice a { color: var(--ink-3); text-decoration: underline; }

/* ─── Footer ─────────────────────────────────────────────────────────────── */
.site-footer {
  border-top: 1px solid var(--rule);
  background: var(--paper);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  padding: 3rem 0 0;
  margin-bottom: 0;
}

.footer-grid p { font-size: 0.85rem; color: var(--ink-2); margin-top: 0.5rem; line-height: 1.7; }
.footer-grid a { color: var(--ink-2); text-decoration: none; font-size: 0.85rem; line-height: 1.9; display: block; }
.footer-grid a:hover { color: var(--accent); }
.footer-grid strong {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
}

.footer-copy {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: 0.06em;
  border-top: 1px solid var(--rule);
  padding: 1.5rem 0;
  margin-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ─── Utility ────────────────────────────────────────────────────────────── */
.success { color: var(--green); }
.error   { color: var(--danger); font-size: 0.9rem; margin-top: 0.5rem; }
.text-dim { color: var(--ink-2); }

/* ─── Scan Form ──────────────────────────────────────────────────────────── */
.scan-form { display: flex; gap: 0; flex-wrap: wrap; margin: 1.5rem 0; }
.scan-form input[type="url"] {
  flex: 1 1 320px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-right: none;
  color: var(--ink);
  padding: 0.75rem 1.25rem;
  font-size: 0.95rem;
  font-family: var(--mono);
  outline: none;
  transition: border-color 0.15s;
}
.scan-form input[type="url"]:focus { border-color: var(--ink); border-right: none; }
.scan-form .btn-primary { border-left: none; }

/* ─── Scan Status ────────────────────────────────────────────────────────── */
.scan-status {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  padding: 1.5rem;
  margin-top: 1.5rem;
  font-family: var(--mono);
  font-size: 0.9rem;
  display: none;
}
.scan-status.visible { display: block; }

/* ─── Article Page ───────────────────────────────────────────────────────── */
.article-hero {
  padding: 4rem 0 3rem;
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
}
.article-hero h1 { font-size: clamp(2rem, 5vw, 3rem); }

.article-body {
  max-width: 720px;
  margin: 0 auto;
  padding: 3rem 1.5rem 5rem;
  line-height: 1.75;
}

.article-body h2 {
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 300;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--rule);
}

.article-body h3 {
  font-family: var(--serif);
  font-size: 1.1rem;
  font-weight: 300;
  margin-top: 1.75rem;
  margin-bottom: 0.5rem;
  color: var(--accent);
}

.article-body p { margin-bottom: 1.1rem; }

.article-body ul, .article-body ol {
  margin: 0.5rem 0 1.1rem 1.5rem;
}
.article-body li { margin-bottom: 0.35rem; }

.article-body code {
  font-family: var(--mono);
  font-size: 0.85em;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  padding: 0.1em 0.35em;
}

.article-body pre {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--rule);
  padding: 1.25rem 1.5rem;
  overflow-x: auto;
  margin: 1.25rem 0;
  font-family: var(--mono);
  font-size: 0.85rem;
  line-height: 1.6;
}
.article-body pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: inherit;
}

.article-body blockquote {
  border-left: 3px solid var(--accent);
  padding: 0.75rem 1.25rem;
  margin: 1.25rem 0;
  background: var(--accent-2);
  color: var(--ink-2);
  font-style: italic;
}

.article-body .callout {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--accent);
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  font-size: 0.9rem;
}
.article-body .callout strong { color: var(--accent); }

.article-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
  margin: 1.25rem 0;
}
.article-body th {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  padding: 0.6rem 0.9rem;
  text-align: left;
  color: var(--ink);
  font-family: var(--mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 500;
}
.article-body td {
  border: 1px solid var(--rule);
  padding: 0.55rem 0.9rem;
  color: var(--ink);
}
.article-body tr:nth-child(even) td { background: var(--paper-2); }

.article-meta {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--ink-3);
  margin-top: 1rem;
  font-family: var(--mono);
}

.article-related {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--accent);
  padding: 1.5rem;
  margin-top: 3rem;
}
.article-related h3 {
  font-family: var(--mono) !important;
  font-size: 0.75rem !important;
  font-weight: 500 !important;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3) !important;
  margin-top: 0 !important;
  margin-bottom: 1rem;
}
.article-related-links {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.article-related-links a {
  font-size: 0.875rem;
  color: var(--accent);
}

/* ─── Article Summary Box ──────────────────────────────────────────────────── */
.article-summary {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--accent);
  padding: 1.5rem;
  margin: 2rem 0 2.5rem;
}

.article-summary-label {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--rule);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.article-summary-label::before {
  content: '◆';
  font-size: 0.5rem;
}

.article-summary-who {
  font-size: 0.875rem;
  color: var(--ink-2);
  margin-bottom: 1rem;
  line-height: 1.6;
}
.article-summary-who strong {
  display: block;
  font-family: var(--mono);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  margin-bottom: 0.3rem;
  font-weight: 500;
}

.article-summary-takeaways { margin-bottom: 1rem; }
.article-summary-takeaways > strong {
  display: block;
  font-family: var(--mono);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  margin-bottom: 0.6rem;
  font-weight: 500;
}
.article-summary-takeaways ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.article-summary-takeaways li {
  font-size: 0.875rem;
  color: var(--ink);
  padding: 0.45rem 0 0.45rem 1.4rem;
  position: relative;
  border-bottom: 1px solid var(--rule);
  line-height: 1.55;
}
.article-summary-takeaways li:last-child { border-bottom: none; }
.article-summary-takeaways li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.75rem;
  top: 0.5rem;
}

.article-summary-readtime {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--ink-3);
  padding-top: 0.75rem;
  border-top: 1px solid var(--rule);
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.article-summary-readtime::before {
  content: '⏱';
  font-size: 0.65rem;
}

/* ─── Spinner ────────────────────────────────────────────────────────────── */
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── Deep scan toggle ───────────────────────────────────────────────────── */
.deep-scan-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 0.6rem;
  margin-bottom: 0.25rem;
}

.deep-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  user-select: none;
  font-size: 0.875rem;
}

.deep-toggle input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0; height: 0;
}

.deep-toggle-track {
  display: inline-block;
  width: 36px; height: 20px;
  background: var(--rule);
  border-radius: 99px;
  position: relative;
  transition: background 0.2s;
  flex-shrink: 0;
}
.deep-toggle-track::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 14px; height: 14px;
  background: var(--ink-3);
  border-radius: 50%;
  transition: transform 0.2s, background 0.2s;
}
.deep-toggle input:checked + .deep-toggle-track { background: var(--accent-2); }
.deep-toggle input:checked + .deep-toggle-track::after {
  transform: translateX(16px);
  background: var(--accent);
}

.deep-toggle-text  { color: var(--ink); font-weight: 500; }
.deep-toggle-sub   { color: var(--ink-2); font-size: 0.8rem; }

.deep-quota-pill {
  font-size: 0.78rem;
  font-family: var(--mono);
  color: var(--ink-2);
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: 99px;
  padding: 0.15rem 0.65rem;
}

/* ─── Deep scan dashboard ────────────────────────────────────────────────── */
#deep-dashboard { margin-bottom: 2rem; }

.deep-dashboard-grid {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  gap: 1.25rem;
  margin: 1.5rem 0 2rem;
}

.dash-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 1.25rem 1.5rem;
}

.dash-card-title {
  font-size: 0.75rem;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-2);
  margin-bottom: 1rem;
  font-weight: 500;
}

.dash-gauge-card {
  grid-row: 1 / 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 160px;
}

.gauge-wrap { position: relative; width: 120px; }
.gauge-svg  { width: 100%; display: block; }
.gauge-bg   { stroke: var(--rule); }
.gauge-arc  {
  stroke: var(--accent);
  stroke-linecap: round;
  transition: stroke-dashoffset 0.8s ease, stroke 0.4s ease;
}

.gauge-score-wrap {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  line-height: 1;
}

.gauge-score {
  display: block;
  font-size: 1.6rem;
  font-weight: 500;
  font-family: var(--mono);
  color: var(--ink);
  line-height: 1;
}

.gauge-label { font-size: 0.7rem; color: var(--ink-3); font-family: var(--mono); }

.gauge-arc.score-good   { stroke: var(--green); }
.gauge-arc.score-warn   { stroke: #d97706; }
.gauge-arc.score-danger { stroke: var(--danger); }

/* Severity distribution */
.sev-bar-wrap {
  height: 28px;
  overflow: hidden;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  margin-bottom: 0.6rem;
}

.sev-bar { display: flex; height: 100%; }
.sev-seg { height: 100%; transition: width 0.5s ease; }
.sev-seg.sev-critical { background: #dc2626; }
.sev-seg.sev-high     { background: #ea580c; }
.sev-seg.sev-medium   { background: #d97706; }
.sev-seg.sev-low      { background: #16a34a; }
.sev-seg.sev-info     { background: var(--blue); }

.sev-bar-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.75rem;
  font-family: var(--mono);
  color: var(--ink-2);
}

.sev-legend-item { display: flex; align-items: center; gap: 0.35rem; }
.sev-legend-dot {
  width: 8px; height: 8px;
  flex-shrink: 0;
}
.sev-legend-dot.sev-critical { background: #dc2626; }
.sev-legend-dot.sev-high     { background: #ea580c; }
.sev-legend-dot.sev-medium   { background: #d97706; }
.sev-legend-dot.sev-low      { background: #16a34a; }
.sev-legend-dot.sev-info     { background: var(--blue); }

.dash-timing {
  margin-top: 0.75rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.75rem;
  font-family: var(--mono);
  color: var(--ink-2);
}

/* Layer scores */
.layer-scores { display: flex; flex-direction: column; gap: 0.5rem; }

.layer-score-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.8rem;
}

.layer-score-name {
  width: 90px;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--ink-2);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.layer-score-bar-wrap {
  flex: 1;
  height: 8px;
  background: var(--paper-2);
  border-radius: 99px;
  overflow: hidden;
  border: 1px solid var(--rule);
}

.layer-score-bar {
  height: 100%;
  border-radius: 99px;
  background: var(--accent);
  transition: width 0.6s ease;
}
.layer-score-bar.score-warn   { background: #d97706; }
.layer-score-bar.score-danger { background: var(--danger); }

.layer-score-value {
  width: 2rem;
  text-align: right;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--ink);
  flex-shrink: 0;
}

.deep-scan-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--accent-2);
  color: var(--accent);
  border: 1px solid var(--rule);
  font-size: 0.7rem;
  font-family: var(--mono);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.15rem 0.55rem;
  flex-shrink: 0;
}

.layer-badge {
  display: inline-block;
  padding: 0.1rem 0.4rem;
  font-size: 0.65rem;
  font-family: var(--mono);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: var(--paper-2);
  color: var(--ink-2);
  border: 1px solid var(--rule);
  flex-shrink: 0;
}

.finding-line {
  font-size: 0.72rem;
  font-family: var(--mono);
  color: var(--ink-2);
}

/* ─── Team / Org chart ───────────────────────────────────────────────────── */
.hero-sm { padding: 3rem 0 2.5rem; border-bottom: 1px solid var(--rule); }

.team-section { padding: 4rem 0; border-top: 1px solid var(--rule); }

.loading-skeleton {
  color: var(--ink-2);
  font-style: italic;
  padding: 1rem 0;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

.section-offline { color: var(--ink-2); font-style: italic; padding: 0.75rem 0; }

.coming-soon-badge {
  display: inline-block;
  font-size: 0.65rem;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.2rem 0.55rem;
  background: var(--accent-2);
  color: var(--accent);
  vertical-align: middle;
  margin-left: 0.5rem;
  font-weight: 500;
}

.preview-note {
  margin-top: 1.25rem;
  font-size: 0.8rem;
  color: var(--ink-2);
  font-style: italic;
  border-left: 3px solid var(--rule);
  padding-left: 0.75rem;
}

.preview-card { opacity: 0.7; pointer-events: none; user-select: none; }
.preview-grid { display: flex; flex-direction: column; gap: 0.5rem; }

.preview-health-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  font-size: 0.875rem;
}

.preview-health-item .health-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.preview-healthy .health-dot { background: var(--green); }
.preview-pending .health-dot { background: var(--ink-3); }
.preview-health-item .preview-label { flex: 1; font-weight: 500; color: var(--ink); }
.preview-health-item .preview-status { font-family: var(--mono); font-size: 0.75rem; }
.preview-healthy .preview-status { color: var(--green); }
.preview-pending .preview-status { color: var(--ink-3); }
.preview-health-item .preview-time { font-size: 0.72rem; min-width: 180px; text-align: right; }
.preview-activity { opacity: 0.75; pointer-events: none; }

/* Org chart */
.org-chart { display: flex; flex-direction: column; align-items: center; gap: 0; }
.org-row { display: flex; justify-content: center; gap: 0.75rem; flex-wrap: wrap; }
.org-board .agent-card { max-width: 200px; }

.org-connector { width: 2px; height: 2rem; background: var(--rule); margin: 0 auto; }

.agent-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 0.75rem 1rem;
  text-align: center;
  min-width: 140px;
  max-width: 180px;
  position: relative;
  transition: background 0.15s;
}
.agent-card:hover { background: var(--paper-2); }

.agent-cto      { border-top: 3px solid var(--accent); }
.agent-sre      { border-top: 3px solid var(--blue); }
.agent-security { border-top: 3px solid #7c3aed; }
.agent-cost     { border-top: 3px solid #ea580c; }

.agent-badge {
  position: absolute;
  top: 0.35rem;
  right: 0.5rem;
  font-family: var(--mono);
  font-size: 0.55rem;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  padding: 0.05rem 0.35rem;
  color: var(--ink-3);
}

.agent-icon { font-size: 1.4rem; margin-bottom: 0.3rem; }
.agent-icon svg { width: 32px; height: 32px; }
.agent-card h3 { font-family: var(--sans); font-size: 0.8rem; font-weight: 600; margin-bottom: 0.15rem; }
.agent-card p  { font-size: 0.68rem; color: var(--ink-2); margin-bottom: 0.3rem; line-height: 1.35; }
.agent-model   { font-size: 0.6rem; color: var(--ink-3); font-family: var(--mono); }

/* Agent live task line */
.agent-task {
  font-family: var(--mono);
  font-size: 0.58rem;
  color: var(--ink-3);
  margin-top: 0.35rem;
  padding-top: 0.3rem;
  border-top: 1px solid var(--rule);
  min-height: 1.6em;
  line-height: 1.35;
  transition: opacity 0.3s;
}
.agent-task.busy { color: var(--ink); }
.agent-task .task-spinner {
  display: inline-block;
  animation: task-spin 0.9s linear infinite;
}
@keyframes task-spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* Activity feed */
.activity-list { display: flex; flex-direction: column; gap: 0.75rem; }

.activity-item {
  display: grid;
  grid-template-columns: auto auto 1fr auto auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.75rem 1rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  font-size: 0.875rem;
}

.agent-tag-cto      { color: var(--accent); }
.agent-tag-sre      { color: var(--blue); }
.agent-tag-security { color: #7c3aed; }
.agent-tag-cost     { color: #ea580c; }

.activity-agent   { font-weight: 500; font-family: var(--mono); font-size: 0.8rem; }
.activity-action  { color: var(--ink-2); font-size: 0.8rem; }
.activity-summary { color: var(--ink); }
.activity-time    { font-size: 0.75rem; color: var(--ink-2); white-space: nowrap; }

.status-completed { color: var(--green); }
.status-failed    { color: var(--danger); }
.status-running   { color: var(--accent); }

/* Kanban */
.kanban-board { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }

.kanban-column {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  padding: 1rem;
  min-height: 120px;
}

.kanban-header {
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-3);
  font-family: var(--mono);
  margin-bottom: 0.75rem;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 0.5rem;
}

.kanban-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 0.75rem;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.kanban-card.priority-high   { border-left: 3px solid var(--danger); }
.kanban-card.priority-medium { border-left: 3px solid #ea580c; }
.kanban-card.priority-low    { border-left: 3px solid var(--rule); }

.kanban-card-title { font-weight: 500; margin-bottom: 0.25rem; }
.kanban-card-meta  { font-size: 0.75rem; display: flex; justify-content: space-between; }
.kanban-empty      { font-style: italic; font-size: 0.85rem; color: var(--ink-3); }

/* ─── Cost dashboard ─────────────────────────────────────────────────────── */
.cost-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 1.5rem;
  margin-bottom: 1rem;
}

.cost-period {
  font-size: 0.75rem;
  color: var(--ink-3);
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-family: var(--mono);
}

.cost-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1rem; }
.cost-item { display: flex; flex-direction: column; gap: 0.25rem; }
.cost-label { font-size: 0.75rem; color: var(--ink-3); font-family: var(--mono); }
.cost-value { font-size: 1.25rem; font-weight: 500; font-family: var(--mono); }

/* Health grid */
.health-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; }

.health-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  font-size: 0.875rem;
}

.health-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.health-item.status-green   .health-dot { background: var(--green); }
.health-item.status-amber   .health-dot { background: #ea580c; }
.health-item.status-red     .health-dot { background: var(--danger); }
.health-item.status-unknown .health-dot { background: var(--ink-3); }

.health-service { font-weight: 500; flex: 1; }
.health-status  { font-size: 0.75rem; color: var(--ink-2); }
.health-time    { font-size: 0.7rem; }

/* Governance table */
.table-scroll { overflow-x: auto; }

.governance-table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
.governance-table th {
  text-align: left;
  padding: 0.5rem 0.75rem;
  border-bottom: 2px solid var(--rule);
  color: var(--ink-2);
  font-weight: 500;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-family: var(--mono);
}
.governance-table td {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
.governance-table tr:hover td { background: var(--paper-2); }

.decision-badge {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-family: var(--mono);
}
.decision-approved  { background: var(--green-bg); color: var(--green); }
.decision-rejected  { background: #fee2e2; color: var(--danger); }
.decision-escalated { background: #fff7ed; color: #ea580c; }

/* ─── Support section ────────────────────────────────────────────────────── */
.support-section { background: var(--paper-2); }

.support-actions { display: flex; gap: 3rem; flex-wrap: wrap; margin: 2rem 0; align-items: flex-start; }
.support-stripe, .support-bmc { flex: 1; min-width: 240px; }

.amount-buttons { display: flex; gap: 0.75rem; margin: 0.75rem 0; flex-wrap: wrap; }
.amount-btn.selected { border-color: var(--accent); color: var(--accent); background: var(--accent-2); }

#support-btn { margin-top: 0.5rem; }
.support-note { font-size: 0.875rem; margin-top: 0.5rem; }
.support-note.error { color: var(--danger); }

.supporter-count {
  font-size: 0.9rem;
  color: var(--ink-2);
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  display: inline-block;
  font-family: var(--mono);
}

.bmc-link { display: inline-block; margin-top: 0.5rem; }
.bmc-footer-link { color: var(--ink-2); font-size: 0.875rem; }
.bmc-footer-link:hover { color: var(--accent); }

/* ─── Next-steps panel (scanner results) ────────────────────────────────── */
.next-steps-panel {
  margin-top: 2.5rem;
  padding: 1.75rem;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 4px solid var(--accent);
}

.next-steps-panel h3 { margin: 0 0 1.25rem; font-size: 1rem; color: var(--ink); font-family: var(--sans); }

.next-steps-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.5rem; }

.next-steps-articles h4,
.next-steps-subscribe h4 {
  margin: 0 0 0.6rem;
  font-size: 0.8rem;
  color: var(--ink);
  font-weight: 600;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.next-steps-articles ul {
  list-style: none;
  margin: 0; padding: 0;
  display: flex; flex-direction: column; gap: 0.4rem;
}
.next-steps-articles li a { font-size: 0.875rem; color: var(--accent); }

.next-steps-subscribe p { font-size: 0.8rem; color: var(--ink-2); margin: 0 0 0.75rem; }

.next-steps-form { display: flex; gap: 0; flex-wrap: wrap; }
.next-steps-form input[type="email"] {
  flex: 1;
  min-width: 160px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-right: none;
  color: var(--ink);
  font-size: 0.875rem;
  padding: 0.45rem 0.85rem;
  outline: none;
  font-family: var(--mono);
  transition: border-color 0.15s;
}
.next-steps-form input[type="email"]:focus { border-color: var(--ink); }

.next-steps-share-wrap { display: flex; align-items: flex-start; }
.next-steps-share { margin-top: 0; font-size: 0.8rem; padding: 0.5rem 1rem; }

/* ─── Support CTA (post-article) ─────────────────────────────────────────── */
.support-cta {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  margin: 2.5rem 0 0;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--rule);
}
.support-cta-text {
  flex: 1;
  font-size: 0.875rem;
  color: var(--ink-2);
  line-height: 1.55;
}
.support-cta-text strong {
  color: var(--ink);
  font-weight: 500;
}
.support-cta-link {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono, monospace);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--ink-2);
  text-decoration: none;
  padding: 8px 14px;
  border: 1px solid var(--rule);
  background: var(--paper);
  transition: color 0.15s, border-color 0.15s, background 0.15s;
  white-space: nowrap;
}
.support-cta-link:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--paper);
  text-decoration: none;
}

/* ─── Mobile nav toggle (shared) ─────────────────────────────────────────── */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--ink, #0e0e0e);
}
.nav-toggle svg { display: block; }


/* ─── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none;
    position: absolute;
    top: 56px; left: 0; right: 0;
    background: var(--paper, #f5f2eb);
    border-bottom: 1px solid var(--rule, #c8c2b4);
    flex-direction: column;
    z-index: 99;
  }
  .site-nav.open { display: flex; }
  .site-nav a {
    border-left: none;
    border-bottom: 1px solid var(--rule, #c8c2b4);
    padding: 14px 1.5rem;
    height: auto;
  }
  .site-nav a:last-child { border-bottom: none; }
}

@media (max-width: 600px) {
  section { padding: 3rem 0; }
  .hero   { padding: 3rem 0 2rem; }
  .hero-sm { padding: 2rem 0 1.5rem; }
  .deep-dashboard-grid { grid-template-columns: 1fr; grid-template-rows: auto; }
  .dash-gauge-card { grid-row: auto; }
  .deep-toggle-sub { display: none; }
}

/* ─── Avatar cluster ──────────────────────────────────────────────────────── */
.hero-avatars {
  display: flex;
  align-items: flex-end;
  gap: 0;
  margin: 2rem 0 1.5rem;
}
.hav {
  border-radius: 50%;
  border: 2px solid var(--paper);
  margin-left: -10px;
  box-shadow: 0 1px 4px rgba(14,14,14,0.10);
}
.hav:first-child { margin-left: 0; }
.hav-1 { z-index: 5; }
.hav-2 { z-index: 4; }
.hav-3 { z-index: 3; }
.hav-4 { z-index: 2; }
.hav-5 { z-index: 1; }

/* ─── Pre-footer CTA strip ───────────────────────────────────────────────── */
.pre-footer-cta {
  max-width: var(--max-w, 1100px);
  margin: 0 auto;
  padding: 2rem 1.5rem 0;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.pre-footer-cta-text {
  flex: 1;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.6;
  min-width: 240px;
}

/* ─── Product CTA block (article in-line) ────────────────────────────────── */
.product-cta {
  border-top: 1px solid var(--rule);
  margin-top: 3rem;
}
.product-cta-inner {
  padding: 2rem 0;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.product-cta-text {
  flex: 1;
  min-width: 220px;
}
.product-cta-text strong {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.25rem;
}
.product-cta-text span {
  font-size: 0.875rem;
  color: var(--ink-2);
  line-height: 1.6;
}
.product-cta-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  flex-shrink: 0;
}
.product-cta-btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-mono, monospace);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 12px 20px;
  transition: background 0.15s;
  border: none;
}
.product-cta-btn:hover { background: var(--accent-hover, #a83508); color: #fff; }
.product-cta-link {
  font-family: var(--font-mono, monospace);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--ink-2);
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s;
}
.product-cta-link:hover { color: var(--accent); }

/* ─── Footer coffee link (shared) ────────────────────────────────────────── */
.footer-bmc {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 0.75rem;
  font-family: var(--font-mono, monospace);
  font-size: 0.8rem;
  color: var(--ink-2);
  text-decoration: none;
  transition: color 0.15s;
}
.footer-bmc:hover {
  color: var(--accent);
  text-decoration: none;
}

/* ─── Article tag colours — perspectives + pattern candidates ─────────────── */
.tag-perspectives {
  background: #fef3e0;
  color: #92600a;
}
.tag-pattern-candidate {
  background: #e8f5e9;
  color: #2e6b35;
}

/* ─── Citation footnotes ──────────────────────────────────────────────────── */
.cite a {
  font-family: var(--mono);
  font-size: 0.7em;
  color: var(--accent);
  text-decoration: none;
  vertical-align: super;
  padding: 0 1px;
}
.cite a:hover { text-decoration: underline; }

.references { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--rule); }
.references h2 {
  font-family: var(--mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  margin-bottom: 1rem;
}
.ref-list { padding-left: 1.5rem; font-size: 0.85rem; color: var(--ink-2); line-height: 1.7; }
.ref-list li { margin-bottom: 0.75rem; }
.ref-back { text-decoration: none; margin-right: 0.5rem; color: var(--accent); }

/* ─── Inert card (non-linked tool card) ──────────────────────────────────── */
.tool-card.is-inert {
  pointer-events: none;
  opacity: 0.7;
  cursor: default;
}

/* ─── Reduced motion ─────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

/* ── Article CTA strip ─────────────────────────────────── */
.article-cta {
  margin: 3rem 0 1rem;
  padding: 1.5rem 2rem;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 4px solid var(--accent);
  border-radius: 2px;
}
.article-cta h3 {
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}
.article-cta p {
  font-size: 0.95rem;
  color: var(--ink-2);
  margin-bottom: 0.75rem;
  line-height: 1.5;
}
.article-cta a.cta-btn {
  display: inline-block;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  padding: 0.5rem 1.2rem;
  text-decoration: none;
  border-radius: 2px;
  transition: background 0.15s;
}
.article-cta a.cta-btn:hover { background: var(--accent); }
.article-cta a.cta-secondary {
  margin-left: 1rem;
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--ink-3);
  text-decoration: none;
  letter-spacing: 0.04em;
}
.article-cta a.cta-secondary:hover { color: var(--accent); }

/* ─── Dark Mode ───────────────────────────────────────────────────────────── */
[data-theme="dark"] {
  --ink:        #f0ede6;
  --ink-2:      #b8b4aa;
  --ink-3:      #888079;
  --paper:      #151412;
  --paper-2:    #1e1c19;
  --paper-3:    #27241f;
  --accent:     #e05a1e;
  --accent-2:   #2a1a12;
  --green:      #3cb371;
  --green-bg:   #0f2b1e;
  --blue-bg:    #0f1e2d;
  --blue:       #5b8fcb;
  --rule:       #2e2b26;
  --shadow-sm:  0 1px 3px rgba(0,0,0,0.35), 0 1px 2px rgba(0,0,0,0.25);
  --shadow:     0 4px 12px rgba(0,0,0,0.40), 0 2px 4px rgba(0,0,0,0.25);
  --shadow-lg:  0 10px 28px rgba(0,0,0,0.50), 0 4px 8px rgba(0,0,0,0.30);
}

/* Hero gradient softener in dark mode */
[data-theme="dark"] .hero,
[data-theme="dark"] .article-hero {
  background: var(--paper);
}

/* Code blocks look better with a slightly lighter surface */
[data-theme="dark"] pre,
[data-theme="dark"] code {
  background: var(--paper-2);
}

/* ─── Theme Toggle Button ─────────────────────────────────────────────────── */
.theme-toggle {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--ink-3);
  background: none;
  border: none;
  border-left: 1px solid var(--rule);
  padding: 0 14px;
  height: 56px;
  cursor: pointer;
  display: flex;
  align-items: center;
  transition: color 0.15s, background 0.15s;
  white-space: nowrap;
  line-height: 1;
}
.theme-toggle:hover {
  color: var(--ink);
  background: var(--paper-2);
}

/* ─── CVE Enrichment Badges (scanner.js — pro scan findings) ─────────────── */
.cvss-badge {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.45rem;
  border-radius: 2px;
  white-space: nowrap;
}
.cvss-badge.cvss-critical { background: #7f1d1d; color: #fff; }
.cvss-badge.cvss-high     { background: var(--accent); color: #fff; }
.cvss-badge.cvss-medium   { background: #fef3c7; color: #92400e; }
.cvss-badge.cvss-low      { background: #eff6ff; color: #1e40af; }

.patch-pill {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.45rem;
  border-radius: 2px;
  white-space: nowrap;
}
.patch-pill.patch-yes { background: #dcfce7; color: #14532d; }
.patch-pill.patch-no  { background: #f1f5f9; color: #475569; }

[data-theme="dark"] .cvss-badge.cvss-medium { background: #78350f; color: #fde68a; }
[data-theme="dark"] .cvss-badge.cvss-low    { background: #1e3a5f; color: #bfdbfe; }
[data-theme="dark"] .patch-pill.patch-yes   { background: #14532d; color: #bbf7d0; }
[data-theme="dark"] .patch-pill.patch-no    { background: #1e1c19; color: var(--ink-3); }

.finding-footer {
  margin-top: 0.6rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}
