/* =====================================================================
   Protocolix design system ("px"). Mobile-first; min-width queries only.
   Breakpoints: 480 / 768 / 1024 / 1200 / 1440.
   ===================================================================== */

/* ---------- Fonts ---------- */
@font-face { font-family: "Sora"; src: url("/px/fonts/sora-latin.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/px/fonts/inter-latin.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/px/fonts/jetbrains-mono-latin.woff2") format("woff2"); font-weight: 400 600; font-display: swap; }

/* ---------- Tokens (spec 3.1) ---------- */
:root {
  --px-red: #E31E24;
  --px-ember: #E9592B;
  --px-amber: #E98A1C;
  --px-gold: #E98A1C;  /* merged into amber (Dec 2026): one text/icon accent; #D0500A is reserved for buttons */
  --px-bg: #0E0D0C;
  --px-surface: #171513;
  --px-surface-2: #201D1A;
  --px-line: #2E2A26;
  --px-line-strong: #6E665D;
  --px-text: #F2F2F2;
  --px-muted: #D9D9D9;
  --px-on-amber: #140C02;
  --px-paper: #EEE8DF;  /* softened (Dec 2026) so black-to-cream changes are less of a jolt; ink texts stay >= 4.7:1 */
  --px-paper-2: #EFE8DD;
  --px-ink: #1C1A17;
  --px-ink-muted: #5E574F;
  --px-amber-ink: #A84A0B;
  --px-grad: linear-gradient(135deg, #E31E24 0%, #E9592B 28%, #E98A1C 62%, #F0A334 100%);
  /* Prime brand colour (owner, Dec 2026): #D0500A. Use rgb(var(--color-prime-brand-rgb) / alpha) for tints. */
  --color-prime-brand-rgb: 208, 80, 10;
  --px-on-cta: var(--px-paper-2);
  --color-prime-brand: rgb(var(--color-prime-brand-rgb));
  /* Call-to-action text is --px-paper-2 (owner choice, Dec 2026); on --color-prime-brand-deep it is 4.6:1. */
  /* Button fill: one shade deeper than the brand colour so cream text reaches 4.6:1 (WCAG AA at any size); 3.5:1 against the page. */
  --color-prime-brand-deep: #B5420A;
  --px-cta: linear-gradient(135deg, rgba(255, 255, 255, 0.10) 0%, transparent 55%), var(--color-prime-brand-deep);
  --px-font-head: "Sora", system-ui, sans-serif;
  --px-font-body: "Inter", system-ui, sans-serif;
  --px-font-mono: "JetBrains Mono", ui-monospace, monospace;
  --px-radius: 14px;
  --px-radius-lg: 20px;
  --px-gutter: 16px;
  --px-header-h: 64px;
  --px-bar-h: 0px;
}
@media (min-width: 768px) { :root { --px-gutter: 24px; } }
@media (min-width: 1200px) { :root { --px-gutter: 40px; --px-header-h: 72px; } }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--px-header-h) + 16px); }
body.px { margin: 0; background: var(--px-bg); color: var(--px-text); font: 400 1rem/1.6 var(--px-font-body); overflow-x: hidden; padding-bottom: var(--px-bar-h); }
.px img, .px video { max-width: 100%; height: auto; display: block; }
.px svg { flex: none; }
.px h1, .px h2, .px h3, .px h4 { font-family: var(--px-font-head); letter-spacing: -0.02em; line-height: 1.12; margin: 0 0 0.5em; font-weight: 700; }
/* Card-sized headings wrap onto two lines; 1.12 is only right for display sizes. */
.px h3, .px h4 { line-height: 1.25; }
.px p { margin: 0 0 1em; }
.px a { color: var(--px-gold); }
.px :focus-visible { outline: 2px solid var(--px-amber); outline-offset: 2px; border-radius: 4px; }
.px .px-skip { position: absolute; left: 16px; top: -100px; z-index: 1000; background: var(--px-amber); color: var(--px-on-amber); padding: 12px 16px; border-radius: 8px; font-weight: 600; text-decoration: none; }
.px .px-skip:focus { top: 12px; }
.px-visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.px-container { width: min(100% - 2 * var(--px-gutter), 1280px); margin-inline: auto; }

/* ---------- Type ---------- */
.px-h2 { font-size: clamp(1.75rem, 1.1rem + 2.6vw, 2.75rem); }
.px-lead { font-size: clamp(1.0625rem, 1rem + 0.4vw, 1.1875rem); color: #F2F2F2; max-width: 36em; }
.px-lead__promise { color: var(--px-text); font-weight: 600; }
.px-muted { color: var(--px-muted); }
.px-kicker { font: 600 0.875rem/1.4 var(--px-font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--px-amber); margin: 0 0 1rem; }
.px-grad-text { background: var(--px-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.px-link { display: inline-flex; align-items: center; gap: 0.4rem; min-height: 44px; font-weight: 600; color: var(--px-gold); text-decoration: none; }
.px-link svg { width: 16px; height: 16px; }
.px-link:hover { text-decoration: underline; }

/* ---------- Sections ---------- */
.px-section { padding-block: clamp(4rem, 3rem + 4vw, 7rem); }
.px-section--surface { background: var(--px-surface); }
.px-section--paper { background: var(--px-paper); color: var(--px-ink); }
.px-section--paper .px-kicker { color: var(--px-amber-ink); }
.px-section--paper .px-muted { color: var(--px-ink-muted); }
.px-section--paper a { color: var(--px-amber-ink); }
.px-section--paper .px-lead, .px-section--paper .px-trust-line { color: var(--px-ink-muted); }
.px-section--paper :focus-visible { outline-color: var(--px-amber-ink); }
.px-section-head { display: grid; gap: 1rem 3rem; margin-bottom: clamp(2rem, 1.5rem + 2vw, 3.5rem); }
.px-section-head p:last-child { margin-bottom: 0; }
@media (min-width: 1024px) { .px-section-head { grid-template-columns: 1.25fr 0.75fr; align-items: end; } }
.px-section__cta { margin-top: clamp(2rem, 1.5rem + 2vw, 3rem); }
.px-grid-bg { background-image: linear-gradient(#1A1816 1px, transparent 1px), linear-gradient(90deg, #1A1816 1px, transparent 1px); background-size: 48px 48px; }

/* ---------- Buttons ---------- */
.px-btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; min-height: 48px; padding: 0.75rem 1.4rem; border-radius: 12px; border: 1px solid transparent; font: 600 1rem/1.2 var(--px-font-body); text-decoration: none; cursor: pointer; transition: background-color 0.15s, border-color 0.15s, box-shadow 0.2s, transform 0.2s, filter 0.2s; }
.px-btn svg { width: 18px; height: 18px; }
.px .px-btn--primary { position: relative; overflow: hidden; isolation: isolate; background: var(--px-cta); color: var(--px-on-cta); font-size: 1.1875rem; font-weight: 700; }
/* A light sweep crosses the button once after the page loads, and again on hover (no endless motion: WCAG 2.2.2). */
.px .px-btn--primary::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, 0.45) 50%, transparent 65%); transform: translateX(-120%); animation: px-cta-shine 1.2s ease-in-out 1.2s 1 both; }
@keyframes px-cta-shine { from { transform: translateX(-120%); } to { transform: translateX(120%); } }
@keyframes px-cta-shine-hover { from { transform: translateX(-120%); } to { transform: translateX(120%); } }
.px .px-btn--primary:hover::after { animation: px-cta-shine-hover 0.9s ease-in-out 1 both; }
.px .px-btn--primary:hover { transform: translateY(-1px); }
.px .px-btn--primary:active { transform: translateY(0); }
@media (prefers-reduced-motion: reduce) { .px .px-btn--primary:hover { transform: none; } .px .px-btn--primary::after { animation: none; display: none; } }
.px .px-btn--quiet { background: var(--px-surface); border-color: var(--px-line-strong); color: var(--px-text); font-weight: 600; }
.px .px-btn--quiet:hover { border-color: var(--px-text); }
.px .px-btn--ghost { background: transparent; border-color: var(--px-line-strong); color: var(--px-text); }
.px .px-btn--ghost:hover { border-color: var(--px-text); }
.px .px-btn--dark { background: var(--px-ink); color: #fff; }
.px-btn--block, .px-cta-row .px-btn--block { width: 100%; }
.px-btn[disabled] { opacity: 0.6; cursor: progress; }
.px-cta-row { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.px-cta-row .px-btn { width: 100%; }
@media (min-width: 480px) { .px-cta-row .px-btn:not(.px-btn--block) { width: auto; } }
/* .px p sets margin-top 0 and outranks a bare class, so scope this under .px to keep the gap below the buttons. */
.px .px-trust-line { font-size: 0.875rem; color: var(--px-muted); margin: 1rem 0 0; }

/* ---------- Reveal on scroll (only when JS runs) ---------- */
.px-reveal-on .px-reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.px-reveal-on .px-reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .px-reveal-on .px-reveal { opacity: 1; transform: none; }
}

/* ---------- Cookie banner ---------- */
/* Cookie banner: slim, bottom of the screen, never over the hero buttons. Both choices look the same (plain). */
.px-cookie { position: fixed; left: var(--px-gutter); right: var(--px-gutter); bottom: calc(12px + var(--px-bar-h)); z-index: 1000; max-width: 920px; margin: 0 auto; background: var(--px-surface-2); color: var(--px-text); border: 1px solid var(--px-line-strong); border-radius: var(--px-radius); padding: 12px 14px; box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5); font-size: 0.9375rem; line-height: 1.5; }
.px-cookie[hidden] { display: none; }
.px-cookie p { margin: 0 0 10px; }
.px-cookie__actions { display: flex; gap: 8px; }
.px-cookie__actions .px-btn { flex: 1 1 0; min-height: 44px; padding: 0.5rem 0.75rem; font-size: 0.9375rem; }
@media (min-width: 768px) {
  .px-cookie { display: flex; align-items: center; gap: 16px; padding: 10px 12px 10px 18px; }
  .px-cookie[hidden] { display: none; }
  .px-cookie p { margin: 0; flex: 1; }
  .px-cookie__actions { flex: none; }
  .px-cookie__actions .px-btn { flex: none; }
}
/* Laptops and up: sit in the right half, over the hero artwork, clear of the headline and buttons on the left. */
@media (min-width: 1024px) { .px-cookie { left: auto; right: var(--px-gutter); max-width: min(620px, 48vw); margin: 0; } }

/* ---------- Header ---------- */
.px-header { position: sticky; top: 0; z-index: 100; background: rgba(14, 13, 12, 0.9); -webkit-backdrop-filter: saturate(1.4) blur(12px); backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--px-line); }
.px-header__bar { position: relative; display: flex; align-items: center; gap: 0.75rem; height: var(--px-header-h); }
.px-header__logo { display: flex; align-items: center; min-height: 44px; }
.px-header__logo img { height: 26px; width: auto; }
.px-header__cta { margin-left: auto; min-height: 44px; padding: 0.5rem 0.75rem; font-size: 0.875rem; white-space: nowrap; }
/* Very small phones: the 19px button label must stay on one line beside the logo and menu. */
@media (max-width: 399px) {
  .px-header__bar { gap: 0.5rem; }
  .px-header__logo img { height: 23px; }
  .px-header__cta { padding: 0.5rem 0.6rem; letter-spacing: -0.01em; }
}
.px-header__menu { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 10px; border: 1px solid var(--px-line-strong); background: transparent; color: var(--px-text); cursor: pointer; }
.px-nojs { display: none; }
html:not(.js) .px-header .px-nojs { display: inline-grid; }
html:not(.js) [data-drawer-open] { display: none; }
.px-nav { display: none; }
@media (min-width: 480px) {
  .px-header__logo img { height: 30px; }
  .px-header__cta { padding: 0.55rem 0.9rem; font-size: 0.9375rem; }
}
@media (min-width: 1200px) {
  .px-header__logo img { height: 36px; }
  .px-nav { display: block; margin-left: auto; }
  .px-header__cta { margin-left: 0.75rem; padding: 0.6rem 1.1rem; }
  .px-header .px-header__menu, html:not(.js) .px-header .px-nojs { display: none; }
}
.px-nav__list { display: flex; align-items: center; gap: 0.125rem; list-style: none; margin: 0; padding: 0; }
.px-nav__item { position: relative; }
.px-nav__item:has(.px-mega--wide) { position: static; }
.px-nav__trigger, .px-nav__link { display: inline-flex; align-items: center; gap: 0.35rem; min-height: 44px; padding: 0.5rem 0.75rem; border: 0; border-radius: 10px; background: transparent; color: #F2F2F2; font: 500 0.9375rem var(--px-font-body); text-decoration: none; cursor: pointer; }
.px .px-nav__link { color: #F2F2F2; }
.px-nav__trigger:hover, .px .px-nav__link:hover, .px-nav__trigger[aria-expanded="true"] { color: var(--px-text); background: var(--px-surface); }
.px-nav__trigger svg { transition: transform 0.2s; }
.px-nav__trigger[aria-expanded="true"] svg { transform: rotate(180deg); }
.px .px-nav__link[aria-current="page"], .px-nav__trigger.is-active { color: var(--px-text); box-shadow: inset 0 -2px 0 var(--px-amber); }
.px-mega { position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%); min-width: 360px; background: var(--px-surface); border: 1px solid var(--px-line); border-radius: var(--px-radius-lg); box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5); padding: 1.25rem; }
.px-mega--wide { min-width: min(900px, calc(100vw - 80px)); left: auto; right: 0; transform: none; }
.px-mega__groups { display: grid; gap: 1.25rem; }
.px-mega--wide .px-mega__groups { grid-template-columns: repeat(3, 1fr); }
.px-mega__label { font: 600 0.8125rem var(--px-font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--px-amber); margin: 0 0 0.5rem; }
.px-mega ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.25rem; }
.px .px-mega__link { display: flex; gap: 0.75rem; padding: 0.65rem; border-radius: 12px; color: var(--px-text); text-decoration: none; }
.px-mega__link:hover, .px-mega__link[aria-current="page"] { background: var(--px-surface-2); }
.px-mega__icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: #2A1F14; border: 1px solid #4A3218; color: var(--px-amber); flex: none; }
.px-mega__link strong { display: block; font-weight: 600; font-size: 0.9375rem; }
.px-mega__link small { display: block; color: var(--px-muted); font-size: 0.8125rem; line-height: 1.4; margin-top: 2px; }
.px-mega__foot { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--px-line); font-size: 0.875rem; }
.px-mega__foot a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
/* No-JS fallback: open menus on hover/focus. */
html:not(.js) .px-nav__item:hover .px-mega, html:not(.js) .px-nav__item:focus-within .px-mega { display: block; }

/* ---------- Mobile drawer ---------- */
.px-drawer { margin: 0 0 0 auto; width: min(100%, 420px); height: 100vh; height: 100dvh; max-height: none; max-width: none; padding: 0; border: 0; border-left: 1px solid var(--px-line); background: var(--px-bg); color: var(--px-text); }
.px-drawer::backdrop { background: rgba(0, 0, 0, 0.6); }
.px-drawer__inner { display: flex; flex-direction: column; height: 100%; }
.px-drawer__top { display: flex; align-items: center; justify-content: space-between; height: 64px; padding: 0 16px; border-bottom: 1px solid var(--px-line); }
.px-drawer__top img { height: 28px; width: auto; }
.px-drawer__body { flex: 1; overflow-y: auto; padding: 8px 16px 16px; }
.px-drawer details { border-bottom: 1px solid var(--px-line); }
.px-drawer summary { display: flex; align-items: center; justify-content: space-between; min-height: 56px; font: 600 1.0625rem var(--px-font-head); cursor: pointer; list-style: none; }
.px-drawer summary::-webkit-details-marker { display: none; }
.px-drawer summary svg { transition: transform 0.2s; }
.px-drawer details[open] summary svg { transform: rotate(180deg); }
.px-drawer__links { list-style: none; margin: 0 0 0.75rem; padding: 0; }
.px .px-drawer__links a { display: flex; align-items: center; min-height: 48px; padding: 0 0.75rem; color: #F2F2F2; text-decoration: none; border-radius: 10px; }
.px .px-drawer__links a[aria-current="page"] { color: var(--px-text); background: var(--px-surface); }
.px .px-drawer__direct { display: flex; align-items: center; min-height: 56px; border-bottom: 1px solid var(--px-line); font: 600 1.0625rem var(--px-font-head); color: var(--px-text); text-decoration: none; }
.px-drawer__contact { display: grid; gap: 0.25rem; margin-top: 1rem; }
.px .px-drawer__contact a { display: flex; align-items: center; gap: 0.6rem; min-height: 48px; color: var(--px-text); text-decoration: none; }
.px-drawer__contact svg { color: var(--px-amber); }
.px-drawer__foot { padding: 16px 16px calc(16px + env(safe-area-inset-bottom)); border-top: 1px solid var(--px-line); }
html.px-lock { overflow: hidden; }

/* ---------- Footer ---------- */
.px-footer { border-top: 1px solid var(--px-line); background: var(--px-bg); padding-top: clamp(3rem, 2.5rem + 2vw, 4.5rem); font-size: 1rem; }
.px-footer__grid { display: grid; gap: 2rem 1.5rem; grid-template-columns: 1fr 1fr; }
.px-footer__brand, .px-footer__col:last-child { grid-column: 1 / -1; }
@media (min-width: 1024px) {
  .px-footer__grid { grid-template-columns: 1.3fr 1fr 1fr 1.2fr; }
  .px-footer__brand, .px-footer__col:last-child { grid-column: auto; }
}
.px-footer__brand img { height: 32px; width: auto; margin-bottom: 1rem; }
.px-footer__brand p, .px-footer address { color: var(--px-muted); font-style: normal; max-width: 32ch; }
.px .px-footer__brand .px-footer__tagline { font: 600 1rem var(--px-font-head); color: var(--px-gold); letter-spacing: -0.01em; margin-bottom: 0.5rem; }

/* Company values (homepage, About) and culture block (Careers) */
.px-values-figure { margin: clamp(2rem, 1.5rem + 2vw, 3rem) auto 0; max-width: 800px; border: 1px solid var(--px-line); border-radius: var(--px-radius-lg); overflow: hidden; }
.px-values-figure img { display: block; width: 100%; height: auto; }
.px-culture { display: grid; gap: 2rem; margin-top: clamp(3rem, 2rem + 3vw, 5rem); align-items: center; }
@media (min-width: 1024px) { .px-culture { grid-template-columns: 1fr 1.1fr; gap: 3rem; } .px-culture .px-values-figure { margin: 0; } }
.px-culture__words { display: flex; flex-wrap: wrap; gap: 0.5rem; list-style: none; margin: 1.5rem 0 0; padding: 0; }
.px-culture__words li { font: 600 0.8125rem var(--px-font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--px-gold); border: 1px solid var(--px-line-strong); border-radius: 999px; padding: 0.45rem 0.9rem; }
.px-footer__title { font: 600 0.8125rem var(--px-font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--px-amber); margin-bottom: 0.75rem; }
.px-footer ul { list-style: none; margin: 0; padding: 0; }
.px .px-footer__col a:not(.px-btn) { display: inline-flex; align-items: center; gap: 0.5rem; min-height: 44px; color: #F2F2F2; text-decoration: none; }
.px .px-footer__col a:not(.px-btn):hover { color: var(--px-text); text-decoration: underline; }
.px-footer__contact li { display: flex; align-items: center; gap: 0.25rem; }
.px-footer__contact svg { color: var(--px-amber); }
.px-footer__col .px-btn { margin-top: 1rem; }
.px-copy { display: inline-grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 10px; background: transparent; color: var(--px-muted); cursor: pointer; }
.px-copy:hover, .px-copy.is-copied { color: var(--px-gold); background: var(--px-surface); }
.px-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem 1.5rem; margin-top: 2.5rem; padding-block: 1.25rem; border-top: 1px solid var(--px-line); color: var(--px-muted); font-size: 0.875rem; }
.px-footer__bottom p { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 0 1.25rem; }
.px .px-footer__bottom a { display: inline-flex; align-items: center; min-height: 44px; color: var(--px-muted); }
.px-linklike { min-height: 44px; padding: 0; border: 0; background: none; color: var(--px-muted); font: inherit; text-decoration: underline; cursor: pointer; }

/* ---------- Mobile quick-contact bar ---------- */
.px-actionbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 90; display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 1px; background: var(--px-line); border-top: 1px solid var(--px-line); padding-bottom: env(safe-area-inset-bottom); }
.px-actionbar[hidden] { display: none; }
.px .px-actionbar__btn { display: flex; align-items: center; justify-content: center; gap: 0.4rem; min-height: 56px; background: var(--px-surface); color: var(--px-text); font: 600 0.9375rem var(--px-font-body); text-decoration: none; }
.px .px-actionbar__btn--primary { background: var(--px-cta); color: var(--px-on-cta); font-size: 1.1875rem; font-weight: 700; }
@media (min-width: 768px) { .px-actionbar, .px-actionbar:not([hidden]) { display: none; } }
/* ---------- Hero ---------- */
.px-hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--px-line); }
.px-hero::before { content: ""; position: absolute; right: -20%; top: -30%; width: 80vmax; height: 80vmax; border-radius: 50%; background: radial-gradient(circle, rgba(233, 138, 28, 0.16), rgba(227, 30, 36, 0.05) 45%, transparent 68%); pointer-events: none; }
.px-hero__inner { position: relative; display: grid; gap: 1.5rem; padding-block: clamp(2.5rem, 1.5rem + 5vw, 6rem); }
.px-hero__title { font-size: clamp(2.5rem, 1.4rem + 4.6vw, 4.25rem); font-weight: 800; line-height: 1.04; margin-bottom: 1.25rem; }
.px-hero__kicker { display: flex; align-items: center; gap: 0.75rem; font: 600 0.8125rem/1.4 var(--px-font-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--px-gold); margin-bottom: 1.25rem; }
.px-hero__kicker::before { content: ""; width: 28px; height: 1.5px; background: var(--px-grad); flex: none; }
.px-hero__copy .px-cta-row { margin-top: 2rem; }
/* The stage holds the still and, on wide screens with motion allowed, the live 3D canvas (px.js block 9) in the
   same box. Both are opaque #0E0D0C renders softened by the same radial mask, so they blend into the hero grid. */
.px-hero__stage { position: relative; width: 100%; max-width: 480px; margin-inline: auto; }
.px-hero__stage > img { width: 100%; }
.px-hero__stage > img, .px-hero__canvas { -webkit-mask-image: radial-gradient(closest-side, #000 80%, transparent); mask-image: radial-gradient(closest-side, #000 80%, transparent); }
.px-hero__canvas, .px-hero__chip { display: none; }
@media (min-width: 1024px) {
  .px-hero__inner { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); align-items: center; min-height: min(820px, calc(100vh - var(--px-header-h))); }
  .px-hero__stage { max-width: none; width: 115%; margin-left: -8%; }
  .px-hero__canvas { display: block; position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transition: opacity 0.7s ease; }
  .px-hero__canvas.is-on { opacity: 1; }
  .px-hero__stage.is-3d > img { opacity: 0; transition: opacity 0.3s linear; }
  .px-hero__chip:not([hidden]) { position: absolute; left: 0; top: 0; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 10px; background: var(--px-surface); border: 1px solid var(--px-line); font: 600 0.8125rem/1.3 var(--px-font-mono); letter-spacing: 0.04em; text-transform: uppercase; color: var(--px-text); white-space: nowrap; pointer-events: none; animation: px-chip-in 0.7s ease both; }
  .px-hero__chip i { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--px-amber); box-shadow: 0 0 10px var(--px-amber); }
  .px-hero__chip small { display: block; font: 500 0.6875rem/1.3 var(--px-font-body); letter-spacing: 0; text-transform: none; color: var(--px-muted); }
}
@keyframes px-chip-in { from { opacity: 0; } to { opacity: 1; } }

/* ---------- At a glance ---------- */
.px-glance { padding-block: clamp(3rem, 2.5rem + 2vw, 4.5rem); }
.px-glance__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.25rem 2rem; margin-bottom: 1.5rem; }
.px-glance__head h2 { font-size: clamp(1.375rem, 1.2rem + 0.8vw, 1.75rem); font-weight: 600; margin: 0; }
.px-glance__head p { margin: 0; font-size: 0.8125rem; }
.px-mono { font-family: var(--px-font-mono); }
.px-sheet { display: grid; grid-template-columns: 1fr; gap: 1px; margin: 0; background: var(--px-line); border: 1px solid var(--px-line); border-radius: var(--px-radius-lg); overflow: hidden; }
.px-sheet > div { background: var(--px-bg); padding: 1.25rem 1.5rem; }
@media (min-width: 480px) { .px-sheet { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .px-sheet { grid-template-columns: repeat(4, 1fr); } }
.px-sheet dt { font: 600 0.8125rem var(--px-font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--px-amber); margin-bottom: 0.4rem; }
.px-sheet dd { margin: 0; }
.px-sheet strong { display: block; font: 600 1.0625rem/1.35 var(--px-font-head); }
.px-sheet span { display: block; color: var(--px-muted); font-size: 0.875rem; margin-top: 0.2rem; }

/* ---------- Cards ---------- */
.px-cards { display: grid; gap: 1.25rem; }
@media (min-width: 768px) { .px-cards--3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .px-cards--3 { grid-template-columns: repeat(3, 1fr); } }
.px-card { display: flex; flex-direction: column; background: var(--px-surface); border: 1px solid var(--px-line); border-radius: var(--px-radius-lg); padding: clamp(1.5rem, 1.2rem + 1vw, 2rem); }
.px-card--hl { border-color: #5A3B1A; background: linear-gradient(180deg, #1E1914, var(--px-surface)); }
.px-card__icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 13px; background: #2A1F14; border: 1px solid #4A3218; color: var(--px-amber); margin-bottom: 1.5rem; }
.px-card h3 { font-size: 1.375rem; font-weight: 600; }
.px-card p { color: var(--px-muted); }
.px-card__link { margin-top: auto; }
.px-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; list-style: none; margin: 0 0 1.25rem; padding: 0; }
.px-chips li { font: 500 0.8125rem var(--px-font-mono); color: var(--px-muted); border: 1px solid var(--px-line); padding: 0.3rem 0.6rem; border-radius: 7px; }
.px-also { margin: 1.75rem 0 0; color: var(--px-muted); }

/* ---------- The Protocol ---------- */
.px-steps { position: relative; display: grid; list-style: none; margin: 0; padding: 0; }
.px-step { position: relative; display: grid; grid-template-columns: 64px 1fr; column-gap: 1.25rem; padding-bottom: 2rem; }
.px-step > :not(.px-step__badge) { grid-column: 2; }
.px-step::before { content: ""; position: absolute; left: 31px; top: 64px; bottom: 0; border-left: 1.5px dashed #4A3A2A; }
.px-step:last-child::before { display: none; }
.px-step__badge { grid-row: 1 / span 3; display: grid; place-items: center; width: 64px; height: 64px; border-radius: 16px; font: 600 0.8125rem var(--px-font-mono); border: 2px solid transparent; background: linear-gradient(var(--px-bg), var(--px-bg)) padding-box, var(--px-grad) border-box; }
.px-step h3 { font-size: 1.25rem; margin: 0.3rem 0 0.4rem; }
.px-step p { color: var(--px-muted); margin: 0 0 0.6rem; font-size: 1rem; }
.px .px-step .px-step__get { font: 500 0.8125rem var(--px-font-mono); color: var(--px-gold); margin: 0; }
@media (min-width: 1024px) {
  .px-steps { grid-template-columns: repeat(5, 1fr); }
  .px-steps::before { content: ""; position: absolute; top: 32px; left: 32px; right: 32px; border-top: 1.5px dashed #4A3A2A; }
  .px-step { display: block; padding: 0 1.5rem 0 0; }
  .px-step::before { display: none; }
  .px-step__badge { position: relative; z-index: 1; margin-bottom: 1.5rem; }
  .px .px-step .px-step__get { border-top: 1px solid var(--px-line); padding-top: 0.75rem; }
}

/* ---------- Recent work (paper band) ---------- */
.px-work { display: grid; gap: 1.5rem; }
@media (min-width: 1024px) { .px-work { grid-template-columns: repeat(2, 1fr); } }
.px-case { display: flex; flex-direction: column; background: #fff; border: 1px solid #E4DCCF; border-radius: var(--px-radius-lg); overflow: hidden; }
.px-case__img { aspect-ratio: 16 / 10; background: var(--px-paper-2); overflow: hidden; }
.px-case__img img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.px-case__body { display: flex; flex-direction: column; flex: 1; padding: clamp(1.5rem, 1.2rem + 1vw, 2.25rem); }
.px-case__meta { font: 500 0.8125rem var(--px-font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--px-amber-ink); margin: 0 0 0.5rem; }
.px-case h3 { font-size: 1.5rem; color: var(--px-ink); }
.px-case p { color: var(--px-ink-muted); }
.px-facts { display: grid; grid-template-columns: 1fr; gap: 0.75rem; margin: auto 0 0; }
@media (min-width: 480px) { .px-facts { grid-template-columns: repeat(3, 1fr); } }
.px-facts div { border-top: 2px solid var(--px-amber); padding-top: 0.6rem; font-size: 0.875rem; color: var(--px-ink-muted); }
.px-facts dt { font: 600 0.875rem var(--px-font-head); color: var(--px-ink); }
.px-facts dd { margin: 0; }

/* ---------- Straight answers ---------- */
.px-qgrid { display: grid; gap: 1rem; }
@media (min-width: 768px) { .px-qgrid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1200px) { .px-qgrid { grid-template-columns: repeat(3, 1fr); } }
.px-q { position: relative; display: flex; flex-direction: column; overflow: hidden; background: var(--px-bg); border: 1px solid var(--px-line); border-radius: var(--px-radius-lg); padding: 1.75rem 1.75rem 1.25rem; }
.px-q::after { content: "?"; content: "?" / ""; position: absolute; right: 16px; top: 0; font: 800 4rem/1 var(--px-font-head); color: #1F1C19; pointer-events: none; }
.px-q h3 { position: relative; z-index: 1; font-size: 1.1875rem; line-height: 1.3; max-width: 88%; }
.px-q p { position: relative; z-index: 1; color: var(--px-muted); font-size: 1rem; }
.px-q .px-link { margin-top: auto; }

/* ---------- Testimonials ---------- */
.px-quotes { display: grid; gap: 1.25rem; margin-top: 2rem; }
.px-section-head + .px-quotes { margin-top: 0; }
@media (min-width: 1024px) { .px-quotes { grid-template-columns: repeat(2, 1fr); } }
.px-quote { margin: 0; background: var(--px-surface); border: 1px solid var(--px-line); border-radius: var(--px-radius-lg); padding: clamp(1.5rem, 1.2rem + 1vw, 2.25rem); }
.px-quote blockquote { margin: 0 0 1.5rem; font: 500 clamp(1.0625rem, 1rem + 0.4vw, 1.25rem)/1.5 var(--px-font-body); }
.px-quote figcaption { display: flex; align-items: center; gap: 0.9rem; }
.px-monogram { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--px-grad); color: var(--px-on-amber); font: 700 1rem var(--px-font-head); flex: none; }
.px-quote cite { display: block; font-style: normal; font-weight: 600; }
.px-quote small { color: var(--px-muted); }

/* ---------- Engineering notes ---------- */
.px-notes { display: grid; gap: 1rem; }
@media (min-width: 768px) { .px-notes { grid-template-columns: repeat(3, 1fr); } }
.px .px-note { display: flex; flex-direction: column; gap: 0.75rem; padding: 1.75rem; background: var(--px-bg); border: 1px solid var(--px-line); border-radius: var(--px-radius-lg); color: var(--px-text); text-decoration: none; transition: border-color 0.2s, transform 0.2s; }
.px .px-note:hover { border-color: var(--px-amber); transform: translateY(-3px); }
@media (prefers-reduced-motion: reduce) { .px .px-note:hover { transform: none; } }
.px-note__tag { font: 600 0.8125rem var(--px-font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--px-amber); }
.px-note h3 { font-size: 1.1875rem; line-height: 1.4; margin: 0; }
.px-note__more { margin-top: auto; display: inline-flex; align-items: center; gap: 0.4rem; color: var(--px-gold); font-weight: 600; }

/* ---------- Contact section + form ---------- */
.px-contact { display: grid; gap: 1.25rem; }
@media (min-width: 1024px) {
  .px-contact { grid-template-columns: 1fr 1.4fr; grid-template-areas: "book form" "direct form"; align-items: start; }
  .px-contact__book { grid-area: book; }
  .px-form { grid-area: form; }
  .px-contact__direct { grid-area: direct; }
}
/* Homepage contact follows the surface "notes" band, so it sits on the page background with raised cards. */
.px-section--contact .px-contact__card { background: var(--px-surface); }
.px-contact__card { background: var(--px-bg); border: 1px solid var(--px-line); border-radius: var(--px-radius-lg); padding: clamp(1.5rem, 1.2rem + 1vw, 2rem); }
.px-contact__card h3 { font-size: 1.25rem; }
.px-contact__direct ul { list-style: none; margin: 0 0 1rem; padding: 0; }
.px-contact__direct li { display: flex; align-items: center; gap: 0.25rem; }
.px .px-contact__direct a { display: inline-flex; align-items: center; gap: 0.6rem; min-height: 48px; color: var(--px-text); text-decoration: none; overflow-wrap: anywhere; }
.px-contact__direct svg { color: var(--px-amber); }
.px-field { display: grid; gap: 0.4rem; margin-bottom: 1rem; }
.px-field label { font-weight: 600; font-size: 1rem; }
.px-field input, .px-field select, .px-field textarea { width: 100%; min-height: 48px; padding: 0.7rem 0.9rem; border-radius: 10px; border: 1px solid var(--px-line-strong); background: var(--px-surface-2); color: var(--px-text); font: 400 1rem var(--px-font-body); }
.px-field textarea { resize: vertical; min-height: 120px; }
.px-field input:focus-visible, .px-field select:focus-visible, .px-field textarea:focus-visible { outline: 2px solid var(--px-amber); outline-offset: 1px; }
.px-field input:user-invalid, .px-field select:user-invalid, .px-field textarea:user-invalid { border-color: var(--px-ember); }
.px-form__more summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; color: var(--px-gold); font-weight: 600; }
.px-form__more[open] summary { margin-bottom: 0.75rem; }
.px-captcha__row { display: grid; grid-template-columns: auto auto; justify-content: start; align-items: center; gap: 0.5rem; }
.px-captcha__row input { grid-column: 1 / -1; }
@media (min-width: 480px) {
  .px-captcha__row { grid-template-columns: auto auto 1fr; justify-content: stretch; }
  .px-captcha__row input { grid-column: 3; }
}
.px-captcha__row img { border-radius: 8px; background: #fff; }
.px-form__status { min-height: 1.6em; margin: 0.75rem 0 0; font-weight: 600; }
.px-form__status.is-ok { color: var(--px-gold); }
.px-form__status.is-error { color: #F2865E; }
.px-form__note { font-size: 0.8125rem; color: var(--px-muted); margin: 0.5rem 0 0; }
