/* Self-hosted Red Hat fonts (variable, latin subset) */
@font-face { font-family: "Red Hat Display"; src: url("/assets/fonts/red-hat-display.woff2") format("woff2"); font-weight: 300 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Red Hat Text"; src: url("/assets/fonts/red-hat-text.woff2") format("woff2"); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Red Hat Mono"; src: url("/assets/fonts/red-hat-mono.woff2") format("woff2"); font-weight: 300 700; font-style: normal; font-display: swap; }

/* Vcodes: light blueprint pages (direction C) with graphite dark sections (direction A). */
:root {
  --ink: #0F2233;
  --text: #405366;
  --muted: #5A6C7E;
  --line: #DDE3EA;
  --grid: #E8EDF2;
  --paper: #FAFBFC;
  --white: #FFFFFF;
  --accent: #F26A00;
  --accent-text: #B84F00;
  --amber: #FFB020;

  --d-bg: #0D1015;
  --d-surface: #151A21;
  --d-cell: #0F1319;
  --d-line: #252C36;
  --d-text: #E8ECF1;
  --d-muted: #9AA5B4;
  --d-dim: #7D8896;

  --display: "Red Hat Display", "Segoe UI", system-ui, sans-serif;
  --body: "Red Hat Text", "Segoe UI", system-ui, sans-serif;
  --mono: "Red Hat Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --wrap: 1280px;
  --gutter: clamp(20px, 5vw, 80px);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.65; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
a:hover { color: var(--accent-text); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3, h4 { font-family: var(--display); color: var(--ink); line-height: 1.12; text-wrap: balance; margin: 0; }
p { margin: 0; }
.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--white); padding: 8px 14px; }
.mono { font-family: var(--mono); }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 12px var(--accent); flex: none; }
.grid-bg { background-color: var(--paper); background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px); background-size: 40px 40px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 8px; font-family: var(--body); font-weight: 600; font-size: 16px; line-height: 1; padding: 15px 24px; border-radius: 4px; text-decoration: none; border: 1.5px solid transparent; transition: background .15s, color .15s, border-color .15s; }
.btn-dark { background: var(--ink); color: var(--white); }
.btn-dark:hover { background: #1C3850; color: var(--white); }
.btn-accent { background: var(--accent); color: var(--d-bg); }
.btn-accent:hover { background: var(--amber); color: var(--d-bg); }
.btn-outline { border-color: var(--ink); color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: var(--white); }
.btn-ghost-dark { border-color: #334050; color: var(--d-text); }
.btn-ghost-dark:hover { border-color: var(--d-muted); color: var(--white); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--white); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 76px; }
.brand img { height: 42px; width: auto; }
.nav { display: flex; align-items: center; gap: 6px; }
.nav > ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 4px; }
.nav-item { position: relative; }
.nav-link { display: inline-flex; align-items: center; gap: 6px; padding: 10px 14px; font-size: 15px; font-weight: 500; text-decoration: none; border-radius: 4px; }
.nav-link[aria-current="page"], .nav-item.is-current > .nav-link { color: var(--accent-text); }
.nav-link svg { width: 10px; height: 10px; }
.submenu { position: absolute; top: 100%; left: 0; min-width: 260px; list-style: none; margin: 0; padding: 8px; background: var(--white); border: 1px solid var(--line); border-radius: 6px; box-shadow: 0 18px 40px rgba(15, 34, 51, .12); opacity: 0; visibility: hidden; transform: translateY(4px); transition: opacity .15s, transform .15s, visibility .15s; }
.nav-item:hover > .submenu, .nav-item:focus-within > .submenu { opacity: 1; visibility: visible; transform: none; }
.submenu a { display: block; padding: 10px 12px; font-size: 15px; text-decoration: none; border-radius: 4px; }
.submenu a:hover { background: var(--paper); }
.nav .btn { margin-left: 10px; padding: 11px 18px; font-size: 15px; }
.menu-toggle { display: none; }

@media (max-width: 960px) {
  .nav { display: none; }
  .menu-toggle { display: block; }
  .menu-toggle summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border: 1.5px solid var(--ink); border-radius: 4px; font-weight: 600; font-size: 15px; }
  .menu-toggle summary::-webkit-details-marker { display: none; }
  .menu-toggle[open] .mobile-nav { display: block; }
  .mobile-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--white); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 24px; max-height: calc(100vh - 76px); overflow-y: auto; }
  .mobile-nav ul { list-style: none; margin: 0; padding: 0; }
  .mobile-nav > ul > li { border-top: 1px solid var(--line); padding: 12px 0; }
  .mobile-nav > ul > li > a { font-weight: 600; font-size: 17px; text-decoration: none; }
  .mobile-nav ul ul { padding: 6px 0 0 14px; }
  .mobile-nav ul ul a { display: block; padding: 6px 0; font-size: 15px; color: var(--text); text-decoration: none; }
}

/* Home hero */
.hero { border-bottom: 1px solid var(--line); padding-block: clamp(56px, 8vw, 96px); }
.hero-top { display: flex; justify-content: space-between; align-items: flex-end; gap: clamp(32px, 5vw, 64px); flex-wrap: wrap; }
.hero h1 { flex: 1 1 520px; font-weight: 900; font-size: clamp(44px, 6vw, 78px); line-height: .98; letter-spacing: -0.03em; max-width: 820px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero-aside { flex: 0 1 380px; display: flex; flex-direction: column; gap: 22px; }
.hero-aside p { font-size: 18px; color: var(--text); }
.hero-aside .actions { display: flex; flex-wrap: wrap; gap: 12px; }

.pipeline { margin-top: clamp(48px, 6vw, 72px); display: grid; grid-template-columns: minmax(170px, 220px) 1fr minmax(0, 560px) 1fr minmax(170px, 220px); align-items: center; }
.pipe-col { display: flex; flex-direction: column; gap: 10px; }
.pipe-col .label { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; color: var(--muted); }
.chip { font-family: var(--mono); font-size: 14px; padding: 10px 14px; background: var(--white); border: 1px solid #CBD5DF; border-radius: 4px; }
.pipe-col.out .chip { border-left: 3px solid var(--accent); }
.connector { height: 2px; margin-inline: 16px; background: repeating-linear-gradient(90deg, var(--accent) 0 10px, transparent 10px 18px); }
.engine { background: var(--white); color: var(--ink); border: 1px solid #CBD5DF; border-top: 4px solid var(--accent); border-radius: 10px; padding: 28px; display: flex; flex-direction: column; gap: 18px; box-shadow: 0 24px 48px rgba(15, 34, 51, .10); }
.engine-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.engine-head strong { font-family: var(--display); font-weight: 900; font-size: 30px; color: var(--ink); }
.engine-head span { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.modules { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.module { background: var(--paper); border: 1px solid var(--line); border-radius: 6px; padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: var(--ink); transition: border-color .15s, background .15s; }
.module:hover { border-color: var(--accent); background: var(--white); color: var(--ink); }
.module small { font-family: var(--mono); font-size: 11px; letter-spacing: .1em; color: var(--accent-text); }
.module span { font-weight: 600; font-size: 16px; }

@media (max-width: 1100px) {
  .pipeline { grid-template-columns: 1fr; gap: 0; max-width: 560px; }
  .pipe-col { flex-direction: row; flex-wrap: wrap; }
  .pipe-col .label { width: 100%; }
  .connector { width: 2px; height: 36px; margin: 16px auto; background: repeating-linear-gradient(180deg, var(--accent) 0 10px, transparent 10px 18px); }
}

/* Section headings */
.section { padding-block: clamp(64px, 8vw, 96px); }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; flex-wrap: wrap; margin-bottom: 28px; }
.section-head h2 { font-weight: 900; font-size: clamp(34px, 4vw, 46px); letter-spacing: -0.02em; }
.section-head .meta { font-family: var(--mono); font-size: 13px; color: var(--muted); }

/* Solutions list */
.list-rows { list-style: none; margin: 0; padding: 0; }
.list-row { display: grid; grid-template-columns: 90px minmax(0, 360px) minmax(0, 1fr) 32px; align-items: center; gap: 24px; padding: 26px 0; border-top: 1px solid var(--line); text-decoration: none; }
.list-rows li:last-child .list-row { border-bottom: 1px solid var(--line); }
.list-row .code { font-family: var(--mono); font-size: 13px; color: var(--accent-text); }
.list-row .name { font-family: var(--display); font-weight: 700; font-size: 26px; line-height: 1.2; }
.list-row .desc { color: var(--text); font-size: 16px; line-height: 1.55; }
.list-row .arrow { font-size: 22px; transition: transform .15s; }
.list-row:hover .arrow { transform: translateX(4px); }
@media (max-width: 760px) {
  .list-row { grid-template-columns: minmax(0, 1fr) 24px; gap: 6px 16px; }
  .list-row .code { grid-column: 1 / -1; }
  .list-row .desc { grid-column: 1; }
  .list-row .arrow { grid-column: 2; grid-row: 2 / 4; }
}

/* Dark sections (Lab notes, CTA) */
.dark { background: var(--d-bg); color: var(--d-text); border-block: 1px solid #222A35; }
.dark h2, .dark h3 { color: var(--d-text); }
.dark .eyebrow { color: var(--d-muted); }
.dark a:hover { color: var(--white); }
.notes-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--d-line); border: 1px solid var(--d-line); border-radius: 10px; overflow: hidden; }
.note { background: var(--d-cell); padding: 30px 28px 32px; display: flex; flex-direction: column; gap: 14px; min-height: 196px; text-decoration: none; color: var(--d-text); transition: background .15s; }
.note:hover { background: #141920; }
.note .tag { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.note h3 { font-weight: 700; font-size: 23px; line-height: 1.25; }
.note p { color: var(--d-muted); font-size: 15px; line-height: 1.55; }
.note .more { margin-top: auto; font-family: var(--mono); font-size: 12px; color: var(--d-dim); }
@media (max-width: 1000px) { .notes-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .notes-grid { grid-template-columns: 1fr; } .note { min-height: 0; } }

.cta { padding-block: clamp(56px, 7vw, 80px); }
.cta .wrap { display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap; }
.cta h2 { font-weight: 900; font-size: clamp(28px, 3.4vw, 38px); letter-spacing: -0.02em; max-width: 720px; }
.cta p { color: var(--d-muted); margin-top: 10px; }

/* Inner page header */
.page-head { border-bottom: 1px solid var(--line); padding-block: clamp(48px, 7vw, 88px); }
.page-head .wrap { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: center; }
.page-head.has-image .wrap { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); }
.page-head h1 { font-weight: 900; font-size: clamp(40px, 5.6vw, 68px); line-height: 1; letter-spacing: -0.03em; margin-top: 16px; }
.page-head .lead { margin-top: 24px; max-width: 44rem; font-size: 19px; line-height: 1.6; color: var(--text); display: flex; flex-direction: column; gap: 12px; }
.page-head .hero-img img { width: 100%; }
/* solution illustrations: half-size; white backgrounds drop out so the grid shows through */
.page-head .hero-img.is-small { justify-self: center; width: 50%; }
.page-head .hero-img.is-small img { mix-blend-mode: multiply; }
.page-head .post-meta { margin-top: 20px; font-family: var(--mono); font-size: 13px; color: var(--muted); }
.page-head.is-compact { padding-block: clamp(36px, 5vw, 56px); }
.page-head.is-compact .wrap { max-width: calc(44rem + 2 * var(--gutter)); }
.page-head.is-compact.has-image .wrap { grid-template-columns: minmax(0, 1fr) minmax(0, 290px); gap: 32px; align-items: stretch; }
.page-head.is-compact h1 { font-size: clamp(28px, 3vw, 38px); line-height: 1.12; letter-spacing: -0.02em; }
/* the image fills the text column's height instead of setting it */
.page-head.is-compact .hero-img { position: relative; min-height: 160px; }
.page-head.is-compact .hero-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }
@media (max-width: 860px) {
  .page-head.has-image .wrap, .page-head.is-compact.has-image .wrap { grid-template-columns: 1fr; }
  .page-head.is-compact .hero-img { max-width: 420px; min-height: 0; }
  .page-head.is-compact .hero-img img { position: static; aspect-ratio: 16 / 10; height: auto; }
}

/* Content rows */
.content { padding-block: clamp(24px, 4vw, 48px) clamp(56px, 7vw, 88px); }
.row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 5vw, 72px); align-items: start; padding-block: clamp(40px, 5vw, 64px); border-bottom: 1px solid var(--line); }
.row:last-child { border-bottom: 0; }
.row > .block:only-child { grid-column: 1 / -1; max-width: 50rem; }
.row > .block:only-child:has(> .video:only-child, > figure:only-child) { max-width: 60rem; margin-inline: auto; width: 100%; }
.block { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.block:has(> figure:only-child) { align-self: center; }
@media (max-width: 860px) { .row { grid-template-columns: 1fr; } }

.block h2, .prose h2 { font-weight: 700; font-size: clamp(24px, 2.4vw, 30px); letter-spacing: -0.01em; }
.block h2 + *, .block figure + h2 { margin-top: 2px; }
.block p, .block li, .prose p, .prose li { color: var(--text); }
.block ul, .prose ul, .prose ol { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.block ul li, .prose ul li { position: relative; padding-left: 22px; }
.block ul li::before, .prose ul li::before { content: ""; position: absolute; left: 2px; top: .7em; width: 8px; height: 2px; background: var(--accent); }
.prose ol { counter-reset: n; }
.prose ol li { counter-increment: n; position: relative; padding-left: 30px; }
.prose ol li::before { content: counter(n) "."; position: absolute; left: 0; font-family: var(--mono); font-size: 14px; color: var(--accent-text); }
.block a, .prose a { color: var(--accent-text); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.block a:hover, .prose a:hover { color: var(--ink); }
.block a.btn, .prose a.btn { color: var(--white); text-decoration: none; align-self: flex-start; }

figure { margin: 0; }
figure img { width: 100%; border-radius: 8px; }
figcaption { margin-top: 12px; font-family: var(--mono); font-size: 13px; line-height: 1.5; color: var(--muted); }
.video { position: relative; aspect-ratio: 16 / 9; width: 100%; max-width: 100%; background: var(--d-bg); border-radius: 8px; overflow: hidden; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
pre.code { margin: 0; background: var(--d-bg); color: var(--d-text); border: 1px solid var(--d-line); border-radius: 8px; padding: 22px 24px; font-family: var(--mono); font-size: 14px; line-height: 1.6; overflow-x: auto; }

/* Articles */
.article { padding-block: clamp(40px, 6vw, 72px) clamp(64px, 8vw, 96px); }
.prose { max-width: 44rem; margin-inline: auto; display: flex; flex-direction: column; gap: 20px; font-size: 18px; line-height: 1.7; }
.prose h2 { margin-top: 20px; }
.prose h3, .prose h4 { font-weight: 700; font-size: 21px; margin-top: 12px; }
.prose figure { margin-block: 12px; }
.prose figure img { border: 1px solid var(--line); }
.prose blockquote { margin: 0; padding-left: 20px; border-left: 3px solid var(--accent); }
.prose strong { color: var(--ink); }

/* Product cards */
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.cards-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card { display: flex; flex-direction: column; gap: 14px; padding: 28px; background: var(--white); border: 1px solid var(--line); border-radius: 10px; text-decoration: none; transition: border-color .15s, box-shadow .15s; }
.card:hover { border-color: #C3CDD8; box-shadow: 0 16px 36px rgba(15, 34, 51, .08); color: var(--ink); }
.card .label { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; color: var(--muted); }
.card h2 { font-weight: 900; font-size: 28px; }
.card p { color: var(--text); font-size: 16px; }
.card .more { margin-top: auto; font-weight: 600; color: var(--accent-text); }
@media (max-width: 960px) { .cards { grid-template-columns: 1fr; max-width: 560px; } }

/* Contact */
.contact-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.contact-grid .card { gap: 10px; }
.contact-grid .big { font-family: var(--mono); font-size: 18px; color: var(--ink); user-select: all; word-break: break-all; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }

/* Footer */
.site-footer { background: var(--white); border-top: 1px solid var(--line); padding-block: 56px 32px; font-size: 15px; }
.footer-top { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 40px; }
.footer-top img { height: 38px; width: auto; }
.footer-top .about { margin-top: 16px; color: var(--muted); max-width: 22rem; }
.footer-top h2 { font-family: var(--mono); font-weight: 500; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }
.footer-top ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.footer-top a { text-decoration: none; }
.footer-bottom { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; font-family: var(--mono); font-size: 13px; color: var(--muted); }
.footer-bottom nav { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-bottom a { text-decoration: none; }
.social { display: flex; gap: 10px; }
.social a { display: inline-flex; width: 38px; height: 38px; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 50%; color: var(--ink); }
.social a:hover { border-color: var(--ink); color: var(--ink); }
.social svg { width: 16px; height: 16px; fill: currentColor; }
@media (max-width: 860px) { .footer-top { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer-top > :first-child { grid-column: 1 / -1; } }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; } }
