/* ============================================================
   BuildMetrx — custom styles
   Only what the Tailwind CDN can't express: transitions tied to
   JS state, background textures, keyframes, and form error states.
   ============================================================ */

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  accent-color: #FE5D01;
}

/* Selection and form-control accent follow the brand orange instead of
   the browser default blue. */

::selection {
  background-color: #FFD5A9;
  color: #0f172a;
}

.bg-blueprint ::selection,
.app ::selection {
  background-color: #FE5D01;
  color: #0f172a;
}

/* ---------- Floating navigation ---------- */

/* <header> is only a positioning layer: fixed and full-width so the bar can
   be centered, but transparent and click-through. Only the bar and the
   mobile menu are interactive. main.js still toggles `is-scrolled` on it. */

#site-header {
  pointer-events: none;
}

.nav-bar,
.nav-menu {
  pointer-events: auto;
  border: 1px solid #e2e8f0;
  background-color: rgba(255, 255, 255, 0.95);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06),
    0 16px 40px -20px rgba(15, 23, 42, 0.35);
  transition: background-color 0.3s ease, border-color 0.3s ease,
    box-shadow 0.3s ease;
}

#site-header.is-scrolled .nav-bar {
  background-color: rgba(255, 255, 255, 0.98);
  border-color: #cbd5e1;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08),
    0 24px 48px -20px rgba(15, 23, 42, 0.45);
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border-radius: 0.5rem;
  padding: 0.5rem 0.875rem;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.25rem;
  color: #334155;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-link:hover,
.nav-link[aria-current="page"] {
  background-color: #f1f5f9;
  color: #0f172a;
}

.nav-link:focus-visible,
.nav-brand:focus-visible,
.nav-toggle:focus-visible,
.nav-dd-btn:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 2px;
}

.nav-wordmark {
  color: #0f172a;
}

.nav-toggle {
  color: #334155;
}

.nav-toggle:hover {
  background-color: #f1f5f9;
}

.nav-divider {
  border-color: #e2e8f0;
}

/* Mobile menu card. Never set `display` here: main.js toggles the [hidden]
   attribute and that must keep working. */

.nav-menu {
  max-height: calc(100vh - 6.5rem);
  max-height: calc(100dvh - 6.5rem);
  overflow-y: auto;
}

.nav-menu .nav-link {
  display: flex;
  padding: 0.75rem 0.875rem;
  font-size: 1rem;
}

/* Six centered links plus the brand and the two actions only fit the
   1024px bar with tighter link spacing; xl restores the full padding. */

@media (min-width: 1024px) and (max-width: 1279.98px) {
  .nav-bar .nav-link {
    padding-left: 0.6rem;
    padding-right: 0.6rem;
    font-size: 0.8125rem;
  }
}

/* ---------- Features dropdown (desktop) ---------- */

.nav-dd {
  display: inline-flex;
  align-items: center;
}

.nav-dd-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 2.25rem;
  margin-left: -0.375rem;
  border-radius: 0.5rem;
  color: #334155;
}

.nav-dd-btn svg {
  transition: transform 0.2s ease;
}

.nav-dd-btn:hover {
  background-color: #f1f5f9;
}

.nav-dd-panel {
  left: 50%;
  transform: translate(-50%, 6px);
  opacity: 0;
  visibility: hidden;
  border: 1px solid #e2e8f0;
  background-color: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08),
    0 24px 48px -20px rgba(15, 23, 42, 0.45);
  transition: opacity 0.18s ease, transform 0.18s ease,
    visibility 0s linear 0.18s;
}

/* Invisible bridge so the pointer can cross the gap without closing */

.nav-dd-panel::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -0.6rem;
  height: 0.6rem;
}

.nav-dd:hover .nav-dd-panel,
.nav-dd.is-open .nav-dd-panel {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
  transition-delay: 0s;
}

.nav-dd.is-open .nav-dd-btn svg {
  transform: rotate(180deg);
}

.nav-dd-item {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  border-radius: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #334155;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-dd-item:hover,
.nav-dd-item[aria-current="page"] {
  background-color: #f1f5f9;
  color: #0f172a;
}

.nav-dd-item:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: -2px;
}

.nav-dd-num {
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 11px;
  color: #FE5D01;
}

.nav-dd-icon {
  display: inline-flex;
  flex-shrink: 0;
  width: 1rem;
  height: 1rem;
  color: #FE5D01;
}

.nav-dd-icon svg {
  width: 100%;
  height: 100%;
}

/* ---------- Section textures ---------- */

.bg-blueprint {
  background-color: #0f172a;
  background-image: radial-gradient(
      ellipse 80% 55% at 50% -10%,
      rgba(254, 93, 1, 0.09),
      transparent 62%
    ),
    linear-gradient(rgba(148, 163, 184, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.055) 1px, transparent 1px);
  background-size: auto, 44px 44px, 44px 44px;
}

/* ---------- Typography helpers ---------- */

/* Section eyebrow as a bordered chip. Light sections get the amber-200
   border and amber-600 text; dark sections (all of which use .bg-blueprint)
   switch to the brighter orange. */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid #FFD5A9;
  border-radius: 9999px;
  padding: 0.35rem 0.7rem;
  background-color: rgba(254, 93, 1, 0.04);
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #C24600;
}

.bg-blueprint .eyebrow {
  border-color: rgba(254, 93, 1, 0.35);
  background-color: rgba(254, 93, 1, 0.08);
  color: #FE5D01;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.5rem;
  padding: 0.8rem 1.6rem;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.25rem;
  transition: background-color 0.2s ease, border-color 0.2s ease,
    color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.btn:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 3px;
}

.btn-amber {
  background-color: #FE5D01;
  color: #0f172a;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.12),
    0 10px 24px -14px rgba(15, 23, 42, 0.5);
}

.btn-amber:hover {
  background-color: #FE8A39;
  transform: translateY(-1px);
}

.btn-blue {
  background-color: #2563eb;
  color: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.12),
    0 10px 24px -14px rgba(15, 23, 42, 0.5);
}

.btn-blue:hover {
  background-color: #3b82f6;
  transform: translateY(-1px);
}

.btn-outline-light {
  border: 1px solid rgba(148, 163, 184, 0.45);
  color: #ffffff;
}

.btn-outline-light:hover {
  border-color: rgba(226, 232, 240, 0.8);
  background-color: rgba(255, 255, 255, 0.06);
}

.btn-outline-dark {
  border: 1px solid #cbd5e1;
  color: #334155;
  background-color: #ffffff;
}

.btn-outline-dark:hover {
  border-color: #94a3b8;
  color: #0f172a;
}

/* ---------- Scroll reveal ---------- */

/* Content is visible by default. main.js adds `js-reveal` to <html> right
   before it starts observing, so a missing or broken script can never leave
   the page blank — it only loses the animation. */

.reveal {
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.js-reveal .reveal {
  opacity: 0;
  transform: translateY(20px);
}

.js-reveal .reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------- Animated chart bars ---------- */

.bar-fill {
  width: var(--w);
  transition: width 1s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.js-reveal .bar-fill {
  width: 0;
}

.js-reveal .bar-fill.is-filled {
  width: var(--w);
}

/* ---------- Vertical chart bars (stacked SVG groups) ---------- */

.vbar {
  transform-box: fill-box;
  transform-origin: 50% 100%;
  transition: transform 1s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.js-reveal .vbar {
  transform: scaleY(0);
}

.js-reveal .vbar.is-filled {
  transform: none;
}

/* ============================================================
   Product mockups — dark app frame
   Every in-page screenshot of BuildMetrx sits inside `.app`, which
   carries the product's dark palette so the mockups look like the
   real system while the page around them stays white.
   ============================================================ */

.app {
  --app-bg: #0e1320;
  --app-card: #111722;
  --app-line: rgba(148, 163, 184, 0.14);
  --app-text: #eef2f7;
  --app-muted: #a3adc2;
  --app-faint: #8a94aa;
  --c-framing: #fe5d01;
  --c-concrete: #4f7df3;
  --c-mep: #3ba586;
  --c-roofing: #a06cf5;
  --c-sitework: #c9a227;
  --c-interior: #e0457b;
  --c-other: #6b7590;
  background-color: var(--app-bg);
  background-image: radial-gradient(
      ellipse 55% 35% at 0% 0%,
      rgba(254, 93, 1, 0.1),
      transparent 65%
    ),
    radial-gradient(
      ellipse 55% 35% at 100% 0%,
      rgba(79, 125, 243, 0.12),
      transparent 65%
    );
  color: var(--app-text);
  border: 1px solid rgba(148, 163, 184, 0.22);
}

.app-card {
  background-color: var(--app-card);
  border: 1px solid var(--app-line);
  border-radius: 0.75rem;
}

.app-muted {
  color: var(--app-muted);
}

.app-faint {
  color: var(--app-faint);
}

.app-line {
  border-color: var(--app-line);
}

.app-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--app-faint);
}

.app-label::after {
  content: "";
  flex: 1;
  height: 1px;
  background-color: var(--app-line);
}

/* Icon tiles */

.app-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 0.5rem;
}

.app-icon svg {
  width: 1rem;
  height: 1rem;
}

.app-icon-sm {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 0.375rem;
}

.app-icon-sm svg {
  width: 0.875rem;
  height: 0.875rem;
}

.app-icon-amber {
  background-color: rgba(254, 93, 1, 0.16);
  color: #fe8a39;
}

.app-icon-blue {
  background-color: rgba(79, 125, 243, 0.18);
  color: #8fb0ff;
}

.app-icon-green {
  background-color: rgba(62, 207, 142, 0.16);
  color: #4ade80;
}

.app-icon-red {
  background-color: rgba(242, 101, 127, 0.16);
  color: #fb8ba0;
}

.app-icon-purple {
  background-color: rgba(160, 108, 245, 0.18);
  color: #c4a5fb;
}

.app-icon-slate {
  background-color: rgba(148, 163, 184, 0.14);
  color: #a3adc2;
}

/* Status pills */

.app-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border-radius: 9999px;
  padding: 0.125rem 0.5rem;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.25rem;
  white-space: nowrap;
}

.app-pill::before {
  content: "";
  width: 0.375rem;
  height: 0.375rem;
  border-radius: 9999px;
  background-color: currentColor;
}

.app-pill.no-dot::before {
  display: none;
}

.app-pill-green {
  background-color: rgba(34, 197, 94, 0.14);
  color: #4ade80;
}

.app-pill-yellow {
  background-color: rgba(245, 197, 66, 0.14);
  color: #f5c542;
}

.app-pill-blue {
  background-color: rgba(79, 125, 243, 0.18);
  color: #a9c0ff;
}

.app-pill-red {
  background-color: rgba(239, 68, 68, 0.16);
  color: #fb8ba0;
}

.app-pill-gray {
  background-color: rgba(148, 163, 184, 0.14);
  color: #b4bccc;
}

/* Time range / filter pill groups */

.app-range {
  display: inline-flex;
  align-items: center;
  gap: 0.125rem;
  border-radius: 9999px;
  border: 1px solid var(--app-line);
  background-color: rgba(255, 255, 255, 0.03);
  padding: 0.125rem;
  font-size: 11px;
  color: var(--app-muted);
  white-space: nowrap;
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.app-range::-webkit-scrollbar {
  display: none;
}

.app-range > span {
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  line-height: 1.25rem;
}

.app-range > .is-active {
  background-color: #ffffff;
  color: #0f172a;
  font-weight: 500;
}

/* Module tab strip */

.app-tabs {
  display: flex;
  gap: 0;
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.app-tabs::-webkit-scrollbar {
  display: none;
}

.app-tab {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 0.25rem;
  border-radius: 0.5rem;
  padding: 0.3rem 0.35rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--app-muted);
}

.app-tab svg {
  width: 0.7rem;
  height: 0.7rem;
  opacity: 0.8;
}

@media (min-width: 768px) {
  .app-tabs {
    flex-wrap: wrap;
    overflow: visible;
    white-space: normal;
  }
}

.app-tab.is-active {
  background-color: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

/* Buttons */

.app-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border-radius: 0.5rem;
  padding: 0.375rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.25rem;
  white-space: nowrap;
  background-color: #fe5d01;
  color: #0f172a;
}

.app-btn-ghost {
  background-color: transparent;
  border: 1px solid rgba(148, 163, 184, 0.3);
  color: var(--app-text);
  font-weight: 500;
}

/* Two-letter avatars */

.app-avatar {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 9999px;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.02em;
  background-color: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
}

.app-avatar-amber {
  background-color: rgba(254, 93, 1, 0.18);
  color: #ffb672;
}

.app-avatar-blue {
  background-color: rgba(79, 125, 243, 0.2);
  color: #a9c0ff;
}

.app-avatar-green {
  background-color: rgba(62, 207, 142, 0.18);
  color: #86efac;
}

.app-avatar-red {
  background-color: rgba(242, 101, 127, 0.18);
  color: #fda4af;
}

/* Tables */

.app-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.app-table th {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid var(--app-line);
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: left;
  color: var(--app-faint);
  white-space: nowrap;
}

.app-table td {
  padding: 0.625rem 0.75rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
  vertical-align: middle;
}

.app-table tr:last-child td {
  border-bottom: 0;
}

/* ---------- Layered mockup stack ---------- */

/* Two app mockups shown as one offset cascade. Both cards live in a pair
   of equal `1fr` rows and are pulled up by the same overlap, so the two
   tracks size from the same content and the shorter card stretches to the
   taller one — identical width, identical height, at every width. The
   white ring on the front card cuts a clean gutter where it crosses the
   card behind it. */

.mockup-stack {
  --stack-shift: 10%;
  --stack-overlap: 3.5rem;
  /* the gutter the front card cuts through the card behind it — set this to
     the section background, or the ring shows up against it */
  --stack-sep: #fff;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.mockup-stack > .mockup-card {
  min-width: 0;
  box-shadow: 0 20px 45px -25px rgba(15, 23, 42, 0.55);
}

@media (min-width: 1024px) {
  .mockup-stack {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: 1fr 1fr;
    gap: 0;
    padding-top: var(--stack-overlap);
    /* These are screenshots, so they carry their own scale. Laying the
       stack out wide and zooming it back down shrinks the whole cascade
       to one screenful without changing a single proportion — and the
       extra layout width lets the content settle on fewer lines. */
    /* The narrower the column, the harder the zoom has to work to keep
       the layout width — and so the card proportions — roughly constant. */
    --stack-zoom: 0.72;
    zoom: var(--stack-zoom);
  }

  @media (min-width: 1280px) {
    .mockup-stack {
      --stack-zoom: 0.8;
    }
  }

  .mockup-stack > .mockup-card {
    position: relative;
    display: flex;
    flex-direction: column;
    margin-top: calc(var(--stack-overlap) * -1);
  }

  .mockup-stack > .mockup-card:first-child {
    z-index: 1;
    margin-right: var(--stack-shift);
    /* the strip the front card lands on is left empty on purpose */
    padding-bottom: calc(var(--stack-overlap) + 0.75rem);
  }

  .mockup-stack > .mockup-card:last-child {
    z-index: 2;
    margin-left: var(--stack-shift);
    box-shadow: 0 0 0 7px var(--stack-sep), 0 30px 60px -24px rgba(15, 23, 42, 0.6);
  }

  /* Mirrored sections put the mockups on the left, so the cascade leans the
     other way and still runs toward the outside of the page. */
  .mockup-stack-mirror > .mockup-card:first-child {
    margin-right: 0;
    margin-left: var(--stack-shift);
  }

  .mockup-stack-mirror > .mockup-card:last-child {
    margin-left: 0;
    margin-right: var(--stack-shift);
  }
}

/* ---------- Placeholder callouts ----------
   Marks copy that still needs real information (pricing, team bios, and so
   on) so nothing reads as final until it is. Delete the callout when the
   real content lands. */

.placeholder-note {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
  border: 1px dashed #FE8A39;
  border-radius: 0.75rem;
  background-color: #FFF7ED;
  padding: 0.75rem 0.875rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: #7A2C00;
}

.placeholder-note svg {
  flex-shrink: 0;
  width: 1rem;
  height: 1rem;
  margin-top: 0.1rem;
  color: #FE5D01;
}

.placeholder-note strong {
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #C24600;
}

.bg-blueprint .placeholder-note {
  border-color: rgba(254, 93, 1, 0.5);
  background-color: rgba(254, 93, 1, 0.08);
  color: #FFD5A9;
}

.bg-blueprint .placeholder-note strong {
  color: #FE8A39;
}

/* ---------- FAQ accordion ---------- */

.faq-item {
  border-bottom: 1px solid #e2e8f0;
}

.faq-item summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  list-style: none;
  cursor: pointer;
  padding: 1.125rem 0;
  font-weight: 600;
  line-height: 1.4;
  color: #0f172a;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary:hover {
  color: #C24600;
}

.faq-item summary:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 2px;
  border-radius: 0.375rem;
}

.faq-item summary svg {
  flex-shrink: 0;
  width: 1.125rem;
  height: 1.125rem;
  margin-top: 0.15rem;
  color: #FE5D01;
  transition: transform 0.2s ease;
}

.faq-item[open] summary svg {
  transform: rotate(45deg);
}

.faq-body {
  padding-bottom: 1.375rem;
  padding-right: 2.25rem;
  color: #475569;
  line-height: 1.65;
}

.faq-body p + p,
.faq-body p + .placeholder-note,
.faq-body .placeholder-note + p {
  margin-top: 0.625rem;
}

.faq-body a {
  font-weight: 500;
  color: #C24600;
  text-decoration: underline;
  text-decoration-color: rgba(194, 70, 0, 0.35);
  text-underline-offset: 3px;
}

.faq-body a:hover {
  color: #993800;
}

/* ---------- Live indicator ---------- */

.live-dot {
  animation: ci-pulse 2s ease-in-out infinite;
}

@keyframes ci-pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}

/* ---------- Form validation states ---------- */

.field-error {
  display: none;
}

.field.has-error .field-error {
  display: block;
}

.field.has-error input,
.field.has-error select {
  border-color: #dc2626;
}

.field.has-error input:focus,
.field.has-error select:focus {
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .bar-fill {
    width: var(--w);
    transition: none;
  }

  .vbar {
    transform: none;
    transition: none;
  }

  .live-dot {
    animation: none;
  }

  .btn:hover {
    transform: none;
  }

  .nav-bar,
  .nav-menu,
  .nav-link,
  .nav-dd-panel,
  .nav-dd-btn svg,
  .faq-item summary svg {
    transition: none;
  }
}

/* ============================================================
   Breakdown — floating tab + breakdown.html
   The tab is an "exploded view" of the system: three slabs (field,
   office, books) that spread apart on hover. Pure CSS, no JS. It is
   injected on every page except breakdown.html itself.
   ============================================================ */

.breakdown-fab {
  position: fixed;
  left: 1.25rem;
  bottom: 1.25rem;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 1rem 0.5rem 0.5rem;
  border-radius: 0.875rem;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background-color: #0f172a;
  background-image: linear-gradient(rgba(148, 163, 184, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.07) 1px, transparent 1px);
  background-size: 12px 12px;
  color: #ffffff;
  text-decoration: none;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.25),
    0 20px 40px -18px rgba(15, 23, 42, 0.7);
  animation: bd-fab-in 0.55s cubic-bezier(0.22, 0.61, 0.36, 1) 0.5s both;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.breakdown-fab:hover,
.breakdown-fab:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(254, 93, 1, 0.75);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.25),
    0 24px 48px -18px rgba(15, 23, 42, 0.8);
}

.breakdown-fab:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 3px;
}

@keyframes bd-fab-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.breakdown-fab-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.625rem;
  border: 1px solid rgba(254, 93, 1, 0.35);
  background-color: rgba(254, 93, 1, 0.12);
}

.breakdown-fab-icon svg {
  width: 2rem;
  height: 2rem;
  overflow: visible;
}

.breakdown-fab .bd-l {
  transition: transform 0.35s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.breakdown-fab:hover .bd-l1,
.breakdown-fab:focus-visible .bd-l1 {
  transform: translateY(-4px);
}

.breakdown-fab:hover .bd-l3,
.breakdown-fab:focus-visible .bd-l3 {
  transform: translateY(4px);
}

.breakdown-fab-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.breakdown-fab-label {
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  line-height: 1.2;
  color: #FE8A39;
}

.breakdown-fab-sub {
  font-size: 0.8125rem;
  line-height: 1.25;
  color: #cbd5e1;
  white-space: nowrap;
}

.breakdown-fab-arrow {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
  color: #94a3b8;
  transition: transform 0.25s ease, color 0.25s ease;
}

.breakdown-fab:hover .breakdown-fab-arrow,
.breakdown-fab:focus-visible .breakdown-fab-arrow {
  transform: translateX(3px);
  color: #FE8A39;
}

@media (max-width: 639.98px) {
  /* Icon only on phones; the link's aria-label still says what it is. */
  .breakdown-fab {
    left: 0.75rem;
    bottom: 0.75rem;
    padding: 0.25rem;
    border-radius: 0.75rem;
  }

  .breakdown-fab-icon {
    width: 2.25rem;
    height: 2.25rem;
  }

  .breakdown-fab-icon svg {
    width: 1.6rem;
    height: 1.6rem;
  }

  .breakdown-fab-text,
  .breakdown-fab-arrow {
    display: none;
  }
}

/* ---------- breakdown.html ---------- */

/* Hero diagram: the three slabs start pressed together and drift apart
   once, then hold. transform-box keeps the motion relative to each slab. */

.bd-slab {
  transform-box: fill-box;
  transform-origin: center;
}

.bd-slab-1 {
  animation: bd-slab-up 1.2s cubic-bezier(0.22, 0.61, 0.36, 1) 0.35s both;
}

.bd-slab-3 {
  animation: bd-slab-down 1.2s cubic-bezier(0.22, 0.61, 0.36, 1) 0.35s both;
}

@keyframes bd-slab-up {
  from { transform: translateY(48px); }
  to { transform: none; }
}

@keyframes bd-slab-down {
  from { transform: translateY(-48px); }
  to { transform: none; }
}

/* Module chips under each step */

.bd-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
  background-color: #f8fafc;
  padding: 0.3rem 0.75rem 0.3rem 0.65rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #334155;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}

.bd-chip:hover {
  border-color: #FFB672;
  background-color: #FFF7ED;
  color: #0f172a;
}

.bd-chip:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 2px;
}

/* Module rows in the map cards */

.bd-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.25rem;
  font-size: 0.9375rem;
  font-weight: 500;
  color: #334155;
  transition: color 0.15s ease;
}

.bd-row:hover {
  color: #C24600;
}

.bd-row:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 2px;
  border-radius: 0.375rem;
}

.bd-mini {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.625rem;
  border: 1px solid #e2e8f0;
  background-color: #f8fafc;
}

.bd-mini svg {
  width: 1.75rem;
  height: 1.75rem;
}

@media (prefers-reduced-motion: reduce) {
  .breakdown-fab,
  .bd-slab-1,
  .bd-slab-3 {
    animation: none;
  }

  .breakdown-fab,
  .breakdown-fab .bd-l,
  .breakdown-fab-arrow,
  .bd-chip,
  .bd-row {
    transition: none;
  }

  .breakdown-fab:hover {
    transform: none;
  }

  .breakdown-fab:hover .bd-l1,
  .breakdown-fab:hover .bd-l3,
  .breakdown-fab:hover .breakdown-fab-arrow {
    transform: none;
  }
}

/* ---------- Flip cards ("Four systems. One source of truth.", home) ----------
   Each card sits icon-side up: the module's icon, large, on the same orange
   as "Metrx" in the logo. It turns over on hover or keyboard focus to show
   its copy. Only mouse/trackpad devices flip; touch devices get the plain
   card, exactly as before. Markup: article.flip-card > .flip-inner >
   .flip-face-icon (absolute overlay) + .flip-face-info (sets the height). */

.flip-card {
  display: flex;
  flex-direction: column;
  perspective: 1400px;
}

.flip-inner {
  position: relative;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
}

.flip-face-info {
  position: relative;
  flex: 1 1 auto;
}

.flip-face-icon {
  display: none;
}

@media (hover: hover) and (pointer: fine) {
  .flip-inner {
    transform-style: preserve-3d;
    transition: transform 0.75s cubic-bezier(0.33, 0, 0.2, 1);
  }

  .flip-card:hover .flip-inner,
  .flip-card:focus-within .flip-inner {
    transform: rotateY(180deg);
  }

  .flip-face-icon,
  .flip-face-info {
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
  }

  .flip-face-info {
    transform: rotateY(180deg);
  }

  .flip-face-icon {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    background-color: #FE5D01; /* the "Metrx" orange from the logo */
    color: #0f172a;
    pointer-events: none;
  }

  /* The icon fills the space above the title, capped so it never crowds the edges. */
  .flip-icon-art {
    display: flex;
    flex: 1 1 auto;
    align-items: center;
    justify-content: center;
    min-height: 0;
    padding: 0.25rem 0 1.25rem;
  }

  .flip-icon-svg {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 12.5rem;
    stroke-width: 1.25;
  }
}

@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: reduce) {
  .flip-inner {
    transition: none;
  }

  .flip-card:hover .flip-inner,
  .flip-card:focus-within .flip-inner {
    transform: none;
  }

  .flip-face-info {
    z-index: 1;
    opacity: 0;
    transform: none;
    transition: opacity 0.2s ease;
  }

  .flip-card:hover .flip-face-info,
  .flip-card:focus-within .flip-face-info {
    opacity: 1;
  }
}

/* ---------- Module orbit (features.html #modules) ----------
   Three dotted rings turn slowly around the BuildMetrx mark. Each node is a
   link to its feature section; the chip inside counter-rotates so icons and
   labels stay upright. Hover or focus anywhere in the orbit pauses it. */

.orbit {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(100%, 31rem);
  aspect-ratio: 1 / 1;
}

.orbit-ring {
  position: absolute;
  border: 2px dotted #cbd5e1;
  border-radius: 9999px;
  animation: orbit-spin var(--orbit-speed) linear infinite var(--orbit-dir, normal);
  /* Each spinning ring is its own layer, so the outer ring's box would sit over
     the inner rings' nodes. Let clicks pass through the ring; nodes take them. */
  pointer-events: none;
}

.orbit-ring-1 { --orbit-speed: 46s; }
.orbit-ring-2 { --orbit-speed: 64s; --orbit-dir: reverse; }
.orbit-ring-3 { --orbit-speed: 84s; }

.orbit-node {
  position: absolute;
  z-index: 1;
  transform: translate(-50%, -50%);
  border-radius: 9999px;
  pointer-events: auto;
}

.orbit-node:hover,
.orbit-node:focus-visible {
  z-index: 3;
}

/* The chip spins the opposite way at the same speed, so it never tilts. */
.orbit-chip {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3.25rem;
  height: 3.25rem;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
  background-color: #ffffff;
  color: #C24600;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06), 0 8px 20px -10px rgba(15, 23, 42, 0.3);
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, scale 0.2s ease;
  animation: orbit-spin var(--orbit-speed) linear infinite;
}

.orbit-ring-1 .orbit-chip,
.orbit-ring-3 .orbit-chip {
  animation-direction: reverse;
}

.orbit-chip svg {
  width: 1.35rem;
  height: 1.35rem;
}

.orbit-node:hover .orbit-chip,
.orbit-node:focus-visible .orbit-chip {
  border-color: #FE5D01;
  background-color: #FE5D01;
  color: #0f172a;
  scale: 1.12;
}

.orbit-node:focus-visible .orbit-chip {
  outline: 2px solid #FE5D01;
  outline-offset: 3px;
}

/* Name tag above the chip; stays in the accessibility tree as the link text. */
.orbit-label {
  position: absolute;
  bottom: calc(100% + 0.5rem);
  left: 50%;
  translate: -50% 4px;
  white-space: nowrap;
  border-radius: 0.375rem;
  background-color: #0f172a;
  padding: 0.3rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.2;
  color: #ffffff;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease, translate 0.15s ease;
}

.orbit-node:hover .orbit-label,
.orbit-node:focus-visible .orbit-label {
  opacity: 1;
  translate: -50% 0;
}

.orbit:hover .orbit-ring,
.orbit:hover .orbit-chip,
.orbit:focus-within .orbit-ring,
.orbit:focus-within .orbit-chip {
  animation-play-state: paused;
}

.orbit-hub {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 6rem;
  height: 6rem;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
  background-color: #ffffff;
  box-shadow: 0 0 0 10px rgba(254, 93, 1, 0.07), 0 12px 30px -12px rgba(15, 23, 42, 0.35);
}

.orbit-hub img {
  width: 3.6rem;
  height: auto;
}

@keyframes orbit-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@media (max-width: 479px) {
  .orbit-chip {
    width: 2.6rem;
    height: 2.6rem;
  }

  .orbit-chip svg {
    width: 1.1rem;
    height: 1.1rem;
  }

  .orbit-hub {
    width: 4.5rem;
    height: 4.5rem;
  }

  .orbit-hub img {
    width: 2.7rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .orbit-ring,
  .orbit-chip {
    animation: none;
  }

  .orbit-chip,
  .orbit-label {
    transition: none;
  }
}

/* Dark variant for the features hero (.bg-blueprint). */
.orbit-dark .orbit-ring {
  border-color: rgba(148, 163, 184, 0.28);
}

.orbit-dark .orbit-chip {
  border-color: rgba(148, 163, 184, 0.25);
  background-color: #111722;
  color: #FE5D01;
  box-shadow: 0 10px 24px -12px rgba(0, 0, 0, 0.7);
}

.orbit-dark .orbit-node:hover .orbit-chip {
  border-color: #FE5D01;
  background-color: #FE5D01;
  color: #0f172a;
}

.orbit-dark .orbit-label {
  background-color: #ffffff;
  color: #0f172a;
}

.orbit-dark .orbit-hub {
  border-color: rgba(254, 93, 1, 0.45);
  background-color: #0b1120;
  box-shadow: 0 0 0 10px rgba(254, 93, 1, 0.08), 0 0 50px -6px rgba(254, 93, 1, 0.35);
}

/* ---------- Home proof strip: endless stat ticker ----------
   Two identical groups slide left by exactly one group width, so the
   loop is seamless. It keeps moving on hover on purpose. Reduced motion
   gets the four stats standing still, wrapped. */

.ticker {
  overflow: hidden;
  padding: 0.75rem 0 1.5rem;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}

.ticker-track {
  display: flex;
  width: max-content;
  animation: ticker-slide 42s linear infinite;
}

.ticker-group {
  display: flex;
  flex-shrink: 0;
  align-items: center;
}

.ticker-item {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  background-color: #fff;
  padding: 1.25rem 1.75rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 12px 32px -18px rgba(15, 23, 42, 0.25);
}

.ticker-value {
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: clamp(1.75rem, 3.4vw, 2.75rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.025em;
  color: #0f172a;
  white-space: nowrap;
}

.ticker-label {
  max-width: 9.5rem;
  font-size: 0.875rem;
  line-height: 1.3;
  color: #64748b;
}

.ticker-mark {
  display: flex;
  padding: 0 1.75rem;
  color: #FE5D01;
}

.ticker-mark svg {
  width: 1.25rem;
  height: 1.25rem;
}

@keyframes ticker-slide {
  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .ticker {
    -webkit-mask-image: none;
    mask-image: none;
  }

  .ticker-track {
    width: auto;
    animation: none;
  }

  .ticker-group {
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
  }

  .ticker-group[aria-hidden="true"],
  .ticker-mark {
    display: none;
  }
}

/* ---------- Orange glow behind product mockups ----------
   main.js tags each mockup's wrapper with .glow-frame inside any
   [data-mockup-glow] region. The glow is a blurred orange light behind
   the frame, set slightly low as if cast on the page. Hover lights it
   on mouse devices; .is-glowing lights it on scroll (home spotlight,
   and every touch device). */

.glow-frame {
  position: relative;
  isolation: isolate;
}

.glow-frame::before {
  content: "";
  position: absolute;
  inset: -2% -6% -9%;
  z-index: -1;
  pointer-events: none;
  border-radius: 3rem;
  background: radial-gradient(closest-side, rgba(254, 93, 1, 0.75) 0%, rgba(254, 93, 1, 0.58) 55%, rgba(254, 93, 1, 0.2) 82%, rgba(254, 93, 1, 0));
  filter: blur(30px);
  opacity: 0;
  transform: translateY(18px) scale(0.9);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.glow-frame.is-glowing::before {
  opacity: 1;
  transform: translateY(18px) scale(1.08);
}

@media (hover: hover) and (pointer: fine) {
  .glow-frame:hover::before {
    opacity: 1;
    transform: translateY(18px) scale(1.08);
  }
}

@media (prefers-reduced-motion: reduce) {
  .glow-frame::before,
  .glow-frame.is-glowing::before,
  .glow-frame:hover::before {
    transform: translateY(18px);
    transition: opacity 0.3s ease;
  }
}

/* ---------- Home "Who it's for": drawing-sheet cards ----------
   The section reads as a light blueprint sheet. Each role name sits in a
   dimension line (diagonal end ticks, like a drawing's measurement
   string) that draws out from the label on reveal. Cards are white
   sheets; hover lifts the sheet, closes orange crop marks in on its
   corners, and turns the icon tile Metrx orange like the flip cards. */

.who-sheets {
  background-color: #f8fafc;
  background-image:
    linear-gradient(to bottom, #f8fafc, rgba(248, 250, 252, 0) 22%, rgba(248, 250, 252, 0) 78%, #f8fafc),
    linear-gradient(rgba(15, 23, 42, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 23, 42, 0.045) 1px, transparent 1px);
  background-size: auto, 44px 44px, 44px 44px;
  background-position: 0 0, center top, center top;
}

.role-sheet {
  display: flex;
  flex-direction: column;
}

.role-dim {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-align: center;
  color: #C24600;
}

.role-dim::before,
.role-dim::after {
  content: "";
  flex: 1 1 0;
  min-width: 1.25rem;
  height: 11px;
  background:
    linear-gradient(135deg, transparent calc(50% - 0.75px), #FE5D01 calc(50% - 0.75px), #FE5D01 calc(50% + 0.75px), transparent calc(50% + 0.75px)) var(--tick-x) 50% / 11px 11px no-repeat,
    linear-gradient(rgba(254, 93, 1, 0.5), rgba(254, 93, 1, 0.5)) 50% 50% / 100% 1px no-repeat;
  transition: transform 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.15s;
}

.role-dim::before {
  --tick-x: 0;
  transform-origin: 100% 50%;
}

.role-dim::after {
  --tick-x: 100%;
  transform-origin: 0 50%;
}

.js-reveal .role-sheet .role-dim::before,
.js-reveal .role-sheet .role-dim::after {
  transform: scaleX(0);
}

.js-reveal .role-sheet.is-visible .role-dim::before,
.js-reveal .role-sheet.is-visible .role-dim::after {
  transform: none;
}

.role-card {
  position: relative;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  background-color: #fff;
  padding: 1.75rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 14px 34px -24px rgba(15, 23, 42, 0.3);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.35s ease;
}

/* Four orange crop marks, just outside the sheet's corners */
.role-card::before {
  --m: #FE5D01;
  content: "";
  position: absolute;
  inset: -9px;
  pointer-events: none;
  background:
    linear-gradient(var(--m), var(--m)) 0 0 / 16px 2px,
    linear-gradient(var(--m), var(--m)) 0 0 / 2px 16px,
    linear-gradient(var(--m), var(--m)) 100% 0 / 16px 2px,
    linear-gradient(var(--m), var(--m)) 100% 0 / 2px 16px,
    linear-gradient(var(--m), var(--m)) 0 100% / 16px 2px,
    linear-gradient(var(--m), var(--m)) 0 100% / 2px 16px,
    linear-gradient(var(--m), var(--m)) 100% 100% / 16px 2px,
    linear-gradient(var(--m), var(--m)) 100% 100% / 2px 16px;
  background-repeat: no-repeat;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 0.3s ease, transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.role-icon {
  display: inline-flex;
  width: 3.25rem;
  height: 3.25rem;
  align-items: center;
  justify-content: center;
  border: 1px solid #FFD5A9;
  border-radius: 0.875rem;
  background-color: rgba(254, 93, 1, 0.06);
  color: #C24600;
  transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

.role-icon svg {
  width: 1.625rem;
  height: 1.625rem;
}

.role-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  margin-top: auto;
  padding-top: 1.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: #C24600;
  transition: color 0.2s ease;
}

.role-link span {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.role-link:hover {
  color: #9a3800;
}

@media (hover: hover) and (pointer: fine) {
  .role-card:hover {
    transform: translateY(-4px);
    border-color: #cbd5e1;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 28px 50px -26px rgba(15, 23, 42, 0.45);
  }

  .role-card:hover::before {
    opacity: 1;
    transform: none;
  }

  .role-card:hover .role-icon {
    border-color: #FE5D01;
    background-color: #FE5D01;
    color: #0f172a;
  }

  .role-card:hover .role-link span {
    transform: translateX(4px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .role-card,
  .role-card::before,
  .role-dim::before,
  .role-dim::after {
    transition: opacity 0.2s ease, background-color 0.2s ease;
  }

  .role-card:hover,
  .role-card:hover::before {
    transform: none;
  }

  .js-reveal .role-sheet .role-dim::before,
  .js-reveal .role-sheet .role-dim::after {
    transform: none;
  }
}

/* ---------- Pause control for moving content (WCAG 2.2.2) ----------
   Each looping animation (stats ticker, module orbit, workflow conveyor,
   breakdown scene) gets a button that toggles .is-paused on its region.
   The choice is kept for the session; reduced-motion starts paused. */

.motion-bar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 0.5rem;
}

.motion-bar-abs {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 2;
  margin: 0;
}

.motion-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2rem;
  padding: 0 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 9999px;
  background: #0f172a;
  color: #ffffff;
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.motion-toggle svg {
  width: 0.8rem;
  height: 0.8rem;
}

.motion-toggle:hover {
  border-color: #FE5D01;
}

.motion-toggle:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 2px;
}

.is-paused,
.is-paused * {
  animation-play-state: paused !important;
}

/* Sideways-scrolling mockup tables are keyboard focusable (A3). */
.app-card[tabindex="0"]:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 2px;
}

/* ---------- Legal pages (privacy, terms, accessibility) ---------- */

.legal {
  color: #334155;
  font-size: 1.0625rem;
  line-height: 1.7;
}

.legal .legal-intro {
  font-size: 1.1875rem;
  color: #0f172a;
}

.legal h2 {
  margin-top: 2.5rem;
  font-family: "Barlow Condensed", Inter, sans-serif;
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.05;
  text-transform: uppercase;
  color: #0f172a;
}

.legal p {
  margin-top: 1rem;
}

.legal ul {
  margin-top: 0.75rem;
  padding-left: 1.4rem;
  list-style: disc;
}

.legal li {
  margin-top: 0.4rem;
}

.legal a {
  color: #C24600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal a:hover {
  color: #993800;
}

.legal a:focus-visible {
  outline: 2px solid #FE5D01;
  outline-offset: 2px;
}

/* ---------- Phone-width safeguard (Nov 23 2026) ----------
   Decorative animations (Bob, the job-site crew, the laser level) can poke a
   few pixels past the edge of a narrow screen mid-move. Clipping sideways
   overflow on the page keeps a phone from ever scrolling sideways. "clip"
   (not "hidden") leaves sticky positioning and vertical scrolling alone. */
@media (max-width: 767.98px) {
  html, body { overflow-x: clip; }
}
