/* Shared components: header, footer, hero workflow, metrics, execution gap */

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s, box-shadow 0.25s;
}
.site-header.is-stuck { border-color: var(--line); box-shadow: 0 6px 24px rgba(12, 26, 75, 0.035); }
.site-header__in { display: flex; align-items: center; justify-content: space-between; min-height: var(--header-h); gap: 16px; }
.brand { display: inline-flex; flex: none; }
.brand img { width: 132px; height: auto; }
.nav-panel { display: none; }
.nav__list a {
  display: block; padding: 14px 0; font-weight: 600; font-size: 1rem; color: var(--navy);
  border-bottom: 1px solid var(--line);
}
.nav__list a[aria-current="page"], .nav__list a:hover { color: var(--blue); }
.nav-panel .btn { width: 100%; margin-top: 20px; }
.header__cta { display: none; }

.nav-toggle {
  position: relative; width: 44px; height: 44px; border-radius: var(--r-sm);
  display: inline-grid; place-items: center; margin-right: -10px;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; display: block; width: 20px; height: 2px; background: var(--navy); border-radius: 2px;
  transition: transform 0.25s var(--ease), background-color 0.2s;
}
.nav-toggle span { position: relative; }
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }

/* no-JS: menu simply stays visible under the brand */
html:not(.js) .site-header__in { flex-wrap: wrap; padding-block: 10px; }
html:not(.js) .nav-panel { display: block; width: 100%; }
html:not(.js) .nav-toggle { display: none; }

.js .nav-panel {
  position: absolute; left: 0; right: 0; top: 100%;
  background: #fff; border-bottom: 1px solid var(--line); box-shadow: 0 24px 40px rgba(12, 26, 75, 0.08);
  padding: 4px var(--gutter) 28px; max-height: calc(100dvh - var(--header-h)); overflow-y: auto;
}
.js .nav-panel.is-open { display: block; animation: nav-in 0.25s var(--ease); }
@keyframes nav-in { from { opacity: 0; transform: translateY(-6px); } }

@media (min-width: 900px) {
  .brand img { width: 148px; }
  .nav-toggle { display: none; }
  .js .nav-panel, .nav-panel, html:not(.js) .nav-panel {
    display: block; position: static; width: auto; padding: 0; border: 0; box-shadow: none; background: none; max-height: none; overflow: visible;
    animation: none;
  }
  .site-header__in { display: grid; grid-template-columns: 1fr auto 1fr; }
  .nav__list { display: flex; gap: clamp(28px, 4vw, 48px); }
  .nav__list a { padding: 8px 0; border: 0; font-size: 0.9375rem; font-weight: 550; color: var(--navy); position: relative; }
  .nav__list a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 2px; background: var(--blue); transform: scaleX(0); transform-origin: left; transition: transform 0.25s var(--ease); }
  .nav__list a:hover::after, .nav__list a[aria-current="page"]::after { transform: scaleX(1); }
  .nav-panel .btn--menu { display: none; }
  .header__cta { display: inline-flex; justify-self: end; }
  html:not(.js) .site-header__in { flex-wrap: nowrap; padding-block: 0; }
}

/* ---------- hero ---------- */
/* Background language (after Locata, not copied): white base, pale-blue atmosphere, a few broad
   concentric ribbon bands sweeping from the lower left, lots of untouched white. No lines, no dots. */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  padding-block: clamp(56px, 8vw, 112px) clamp(72px, 9vw, 120px);
  background: #e3eefc;
  text-align: center;
}
/* one atmospheric layer for the whole section (inset: 0 — always covers the full hero height) */
.hero__bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.hero__bg::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle farthest-corner at -6% 122%, transparent 30%, rgba(255, 255, 255, 0.54) calc(30% + 10px), rgba(166, 199, 245, 0.3) calc(30% + 30px), rgba(186, 213, 249, 0.2) 34.0%, rgba(205, 225, 251, 0) 39.0%),
    radial-gradient(circle farthest-corner at -6% 122%, transparent 43%, rgba(255, 255, 255, 0.54) calc(43% + 10px), rgba(166, 199, 245, 0.3) calc(43% + 30px), rgba(186, 213, 249, 0.2) 47.0%, rgba(205, 225, 251, 0) 52.0%),
    radial-gradient(circle farthest-corner at -6% 122%, transparent 56%, rgba(255, 255, 255, 0.54) calc(56% + 10px), rgba(166, 199, 245, 0.3) calc(56% + 30px), rgba(186, 213, 249, 0.2) 60.0%, rgba(205, 225, 251, 0) 65.0%),
    radial-gradient(circle farthest-corner at -6% 122%, transparent 69%, rgba(255, 255, 255, 0.54) calc(69% + 10px), rgba(166, 199, 245, 0.3) calc(69% + 30px), rgba(186, 213, 249, 0.2) 73.0%, rgba(205, 225, 251, 0) 78.0%),
    radial-gradient(circle farthest-corner at -6% 122%, transparent 82%, rgba(255, 255, 255, 0.54) calc(82% + 10px), rgba(166, 199, 245, 0.3) calc(82% + 30px), rgba(186, 213, 249, 0.2) 86.0%, rgba(205, 225, 251, 0) 91.0%),
    radial-gradient(120% 90% at 50% 18%, #ffffff 0%, #f6faff 34%, #e8f1fd 68%, #dbe8fb 100%);
}
/* white stays dominant behind the headline */
.hero__bg::after {
  content: ""; position: absolute; left: 50%; top: 0; width: min(1100px, 150%); height: min(64%, 640px); transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0));
}
@media (max-width: 899.98px) {
  .hero__bg::before {
    background:
    radial-gradient(circle farthest-corner at -70% 112%, transparent 34%, rgba(255, 255, 255, 0.62) calc(34% + 10px), rgba(166, 199, 245, 0.34) calc(34% + 30px), rgba(186, 213, 249, 0.2) 37.1%, rgba(205, 225, 251, 0) 41.0%),
    radial-gradient(circle farthest-corner at -70% 112%, transparent 45%, rgba(255, 255, 255, 0.62) calc(45% + 10px), rgba(166, 199, 245, 0.34) calc(45% + 30px), rgba(186, 213, 249, 0.2) 48.1%, rgba(205, 225, 251, 0) 52.0%),
    radial-gradient(circle farthest-corner at -70% 112%, transparent 56%, rgba(255, 255, 255, 0.62) calc(56% + 10px), rgba(166, 199, 245, 0.34) calc(56% + 30px), rgba(186, 213, 249, 0.2) 59.1%, rgba(205, 225, 251, 0) 63.0%),
    radial-gradient(circle farthest-corner at -70% 112%, transparent 67%, rgba(255, 255, 255, 0.62) calc(67% + 10px), rgba(166, 199, 245, 0.34) calc(67% + 30px), rgba(186, 213, 249, 0.2) 70.2%, rgba(205, 225, 251, 0) 74.0%),
    radial-gradient(circle farthest-corner at -70% 112%, transparent 78%, rgba(255, 255, 255, 0.62) calc(78% + 10px), rgba(166, 199, 245, 0.34) calc(78% + 30px), rgba(186, 213, 249, 0.2) 81.2%, rgba(205, 225, 251, 0) 85.0%),
    radial-gradient(circle farthest-corner at -70% 112%, transparent 89%, rgba(255, 255, 255, 0.62) calc(89% + 10px), rgba(166, 199, 245, 0.34) calc(89% + 30px), rgba(186, 213, 249, 0.2) 92.2%, rgba(205, 225, 251, 0) 96.0%),
    radial-gradient(140% 70% at 50% 12%, #ffffff 0%, #f5f9ff 36%, #e7f0fd 70%, #dae7fb 100%);
  }
  .hero__bg::after { height: 42%; width: 170%; }
}
.hero__copy { max-width: 52rem; margin-inline: auto; }
.hero .eyebrow { margin-bottom: 22px; }
.hero .h1 { max-width: 15em; margin-inline: auto; }
.nb { white-space: nowrap; }
.hero .lead { margin: 26px auto 0; max-width: 40rem; }
.hero__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 38px; }
@media (max-width: 599.98px) { .hero .flow { margin-top: 84px; } }

/* workflow diagram: work queues -> AI workforce -> completed actions (same story on every device) */
.flow { margin-top: clamp(56px, 7vw, 92px); display: grid; justify-items: center; gap: 0; text-align: left; }
.flow__label { font-size: 0.9375rem; font-weight: 650; color: var(--navy); line-height: 1.3; text-align: center; }
.flow__panel {
  width: 100%; max-width: 340px; padding: 10px;
  background: #fff; border-radius: var(--r-md);
  box-shadow: 0 0 0 1px rgba(214, 227, 245, 0.55), 0 1px 2px rgba(12, 26, 75, 0.03), 0 16px 36px -16px rgba(11, 111, 220, 0.18);
}
.flow__panel li {
  display: flex; align-items: center; gap: 12px; height: 44px; padding: 0 12px;
  font-size: 0.875rem; font-weight: 600; color: var(--navy); border-radius: var(--r-sm);
}
.flow__panel li + li { margin-top: 4px; }
.flow__panel li:nth-child(even) { background: var(--blue-50); }
.flow__panel svg { width: 20px; height: 20px; flex: none; stroke: var(--blue); }
.flow__col { display: flex; flex-direction: column; align-items: center; width: 100%; }
.flow__col .flow__label { min-height: 52px; display: flex; align-items: flex-end; padding-bottom: 12px; }

/* mobile/tablet: the same four-wire topology, reflowed vertically
   Work Queues panel → 4 wires converge → AI Workforce node → 4 wires fan out → Completed Actions panel */
.flow__core { display: flex; flex-direction: column; align-items: center; position: relative; width: 100%; }
.flow__vw { display: block; width: 100%; max-width: 340px; height: auto; aspect-ratio: 300 / 84; overflow: visible; }
.flow__vw--in { order: 1; margin-bottom: 14px; }
.flow__core .flow__node { order: 2; }
.flow__core .flow__label { order: 3; margin: 20px 0 14px; }
.flow__vw--out { order: 4; }
.flow__vw .w { fill: none; stroke: var(--blue-300); stroke-width: 1.2; opacity: 0.75; }
.flow__vw .a { fill: var(--blue-300); }
.flow__vw .d {
  fill: none; stroke: var(--blue); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 0.5 200; opacity: 0;
  animation: vdot 3.2s cubic-bezier(0.45, 0, 0.35, 1) infinite; animation-delay: var(--dl, 0s);
}
@keyframes vdot { 0% { stroke-dashoffset: 0; opacity: 0; } 14%, 86% { opacity: 0.9; } 100% { stroke-dashoffset: -99.5; opacity: 0; } }
.flow > .flow__col:last-child { flex-direction: column-reverse; }
.flow > .flow__col:last-child .flow__label { min-height: 0; align-items: flex-start; padding: 14px 0 0; }
.flow__node {
  position: relative; width: 104px; height: 104px; border-radius: 28px; display: grid; place-items: center;
  background: #fff; box-shadow: 0 0 0 1px rgba(214, 227, 245, 0.8), 0 2px 6px rgba(12, 26, 75, 0.04), 0 22px 50px -10px rgba(11, 111, 220, 0.2);
}
.flow__node::before, .flow__node::after { content: ""; position: absolute; border-radius: 50%; border: 1px solid var(--blue-200); pointer-events: none; }
.flow__node::before { inset: -16px; opacity: 0.8; animation: ring 3.2s cubic-bezier(0.45, 0, 0.35, 1) infinite; animation-delay: 1.5s; }
.flow__node::after { display: none; }
.flow__node img { width: 54px; height: auto; }
.flow__wires { display: none; }
@keyframes ring { 0%, 100% { opacity: 0.6; transform: scale(1); } 30% { opacity: 1; transform: scale(1.05); border-color: var(--blue-300); } }

@media (min-width: 900px) {
  .flow { grid-template-columns: clamp(236px, 22vw, 262px) 1fr 176px 1fr clamp(236px, 22vw, 262px); align-items: end; justify-items: stretch; }
  .flow__panel { max-width: none; height: 208px; }
  .flow__vw { display: none; }
  .flow > .flow__col:last-child { flex-direction: column; }
  .flow > .flow__col:last-child .flow__label { min-height: 52px; align-items: flex-end; padding: 0 0 12px; }
  .flow__core { display: grid; grid-template-rows: 52px 208px; justify-items: center; padding: 0; height: 260px; }
  .flow__core .flow__label { order: 0; margin: 0; display: flex; align-items: flex-end; padding-bottom: 12px; }
  .flow__node { align-self: center; }
  .flow__node::before { inset: -26px; animation-duration: 5.2s; animation-delay: 1.2s; }
  .flow__node::after { display: block; inset: -54px; opacity: 0.4; }
  .flow__wires { display: block; height: 208px; width: 100%; overflow: visible; }
  .flow__wires path { fill: none; vector-effect: non-scaling-stroke; }
  .flow__wires .w { stroke: var(--blue-300); stroke-width: 1.2; opacity: 0.75; }
  .flow__wires .d { stroke: var(--blue); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 0.01 900; animation: dot 5.2s linear infinite; animation-delay: var(--dl, 0s); opacity: 0.85; }
}
@keyframes dot { from { stroke-dashoffset: 0; } to { stroke-dashoffset: -700; } }
@media (prefers-reduced-motion: reduce) {
  .flow__wires .d, .flow__vw .d { display: none; }
}

/* ---------- metrics ---------- */
.metrics { border-block: 1px solid rgba(214, 227, 245, 0.7); background: #fff; }
.metrics dl { display: grid; grid-template-columns: repeat(2, 1fr); padding-block: clamp(36px, 5.5vw, 72px); }
.metric { display: grid; justify-items: center; align-content: start; text-align: center; padding: 28px 12px; }
.metric::before { content: ""; width: 46px; height: 46px; border-radius: 50%; margin-bottom: 18px; background: var(--icon) center / 22px no-repeat, linear-gradient(180deg, #e9f2fe, #dde9fb); box-shadow: inset 0 0 0 1px rgba(11, 111, 220, 0.06); }
.metric dt { order: 3; margin-top: 8px; font-size: var(--fs-small); color: var(--ink-muted); line-height: 1.45; }
.metric dd { order: 2; font-size: clamp(2.125rem, 1.55rem + 1.8vw, 2.75rem); font-weight: 700; color: var(--navy); letter-spacing: -0.028em; line-height: 1.05; }
.metric:nth-child(n + 3) { border-top: 1px solid var(--line); }
.metric:nth-child(even) { border-left: 1px solid var(--line); }
.metric--actions { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b6fdc' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8'/%3E%3Cpath d='M12 7.5V12l3 2'/%3E%3C/svg%3E"); }
.metric--chart { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b6fdc' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 20v-6M12 20V6M18 20v-9'/%3E%3C/svg%3E"); }
.metric--doc { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b6fdc' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 3h7l4 4v14H7z'/%3E%3Cpath d='M14 3v4h4M10 13l2 2 3-4'/%3E%3C/svg%3E"); }
.metric--layers { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b6fdc' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3 3 8l9 5 9-5z'/%3E%3Cpath d='M3 12l9 5 9-5M3 16l9 5 9-5'/%3E%3C/svg%3E"); }
@media (min-width: 900px) {
  .metrics dl { grid-template-columns: repeat(4, 1fr); }
  .metric { padding: 8px 24px; border: 0 !important; }
  .metric::before { width: 52px; height: 52px; margin-bottom: 22px; background-size: 25px, auto; }
  .metric::before { width: 52px; height: 52px; margin-bottom: 22px; background-size: 25px, auto; }
  .metric + .metric { border-left: 1px solid var(--line) !important; }
}

/* ---------- execution gap ---------- */
.gap { position: relative; padding-block: var(--section-y); overflow: hidden; }
.gap .section-head { max-width: 62rem; }
.gap .lead { max-width: 52rem; text-wrap: pretty; }
.gap::before, .gap::after {
  content: ""; position: absolute; top: 50%; width: min(220px, 18vw); aspect-ratio: 1; transform: translateY(-50%);
  background-image: radial-gradient(var(--blue-200) 1.4px, transparent 1.6px); background-size: 18px 18px;
  -webkit-mask-image: radial-gradient(closest-side, #000, transparent); mask-image: radial-gradient(closest-side, #000, transparent);
}
.gap::before { left: 2%; }
.gap::after { right: 2%; }
@media (max-width: 640px) { .gap::before, .gap::after { display: none; } }

/* ---------- footer: deep navy closing section ---------- */
.site-footer {
  --f-ink: #f4f7fd; --f-muted: #a9b8d6; --f-line: rgba(169, 184, 214, 0.18);
  position: relative; isolation: isolate; overflow: hidden;
  background: #0c1a4b; color: var(--f-muted);
  padding-block: clamp(64px, 8vw, 104px) 32px;
}
.site-footer::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(60% 90% at 100% 0%, rgba(59, 141, 239, 0.16), transparent 70%), radial-gradient(40% 70% at 0% 100%, rgba(59, 141, 239, 0.08), transparent 70%);
}
.site-footer__top { display: grid; gap: 48px; }
.site-footer .brand img { width: 168px; height: auto; }
.site-footer__tag { margin-top: 20px; max-width: 30ch; color: var(--f-ink); font-size: 1.0625rem; line-height: 1.5; }
.site-footer__cta { display: inline-flex; align-items: center; gap: 10px; margin-top: 22px; min-height: 44px; font-weight: 650; font-size: 0.9375rem; color: #8fc0ff; }
.site-footer__cta svg { width: 15px; height: 15px; transition: transform 0.25s var(--ease); }
.site-footer__cta:hover { color: #fff; }
.site-footer__cta:hover svg { transform: translateX(3px); }
.site-footer__nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 36px 24px; }
.site-footer h2 { margin-bottom: 14px; font-size: 0.75rem; font-weight: 650; letter-spacing: 0.14em; text-transform: uppercase; color: var(--f-muted); }
.site-footer__group li a { display: inline-flex; align-items: center; min-height: 40px; font-size: 1rem; font-weight: 500; color: var(--f-ink); transition: color 0.2s; }
.site-footer__group li a:hover { color: #8fc0ff; }
.site-footer__base {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px;
  margin-top: clamp(48px, 6vw, 80px); padding-top: 24px; border-top: 1px solid var(--f-line);
  font-size: 0.875rem; color: var(--f-muted);
}
.site-footer__top-link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; color: var(--f-muted); }
.site-footer__top-link svg { width: 14px; height: 14px; transform: rotate(-90deg); }
.site-footer__top-link:hover { color: var(--f-ink); }
.site-footer :focus-visible { outline-color: #8fc0ff; }
@media (min-width: 640px) {
  .site-footer__nav { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 960px) {
  .site-footer__top { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 64px; align-items: start; }
  .site-footer__nav { gap: 48px; padding-top: 6px; }
}
