/* Home's header, footer and tokens for the static HTML pages (/start, /release-notes, the agent-swarm post).
   A copy of components/Nav, components/sections/Footer and the :root block of app/globals.css: change them together. */

@font-face {
  font-family: "SL DM Sans";
  src: url("/blog/agent-swarm-assets/DMSans-opsz.woff2") format("woff2");
  font-weight: 100 1000;
  font-display: swap;
}
@font-face {
  font-family: "SL Newsreader";
  src: url("/blog/agent-swarm-assets/Newsreader-opsz.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "SL Instrument Sans";
  src: url("/fonts/81845a8d6b81fcf2.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  --paper: hsl(0 0% 100%);
  --paper-2: hsl(60 5.9% 96.7%);
  --ink: hsl(0 0% 3.9%);
  --ink-2: hsl(0 0% 16.9%);
  --ink-3: hsl(0 0% 35.3%);
  --ink-4: hsl(0 0% 54.9%);
  --line: hsl(60 3.6% 89%);
  --line-2: hsl(60 3% 80.6%);
  --rule: hsl(0 0% 7.8%);
  --accent: hsl(11 78.5% 49.2%);
  --accent-deep: hsl(11 87.6% 37.8%);
  --dark: hsl(240 4.3% 4.5%);
  --font-sans: "SL DM Sans", "Helvetica Neue", Arial, sans-serif;
  --font-serif: "SL Newsreader", "Times New Roman", Georgia, serif;
  --font-instrument: "SL Instrument Sans", "Helvetica Neue", Arial, sans-serif;
  --fs-lead: clamp(1.125rem, 1.02rem + 0.42vw, 1.4rem);
  --fs-label: 0.75rem;
  --tracking-label: 0.18em;
  --tracking-display: -0.035em;
  --gutter: clamp(20px, 5vw, 72px);
  --maxw: 1440px;
  --nav-h: 76px;
  --radius-button: 999px;
  --ease-out: cubic-bezier(0.19, 1, 0.22, 1);
  --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --dur-press: 160ms;
  --dur-hover: 200ms;
}

.sc-header,
.sc-footer {
  font-family: var(--font-sans);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}
.sc-header *,
.sc-footer * {
  box-sizing: border-box;
}
.sc-header ul,
.sc-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.sc-header a,
.sc-footer a {
  color: inherit;
  text-decoration: none;
}
.sc-header :focus-visible,
.sc-footer :focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 4px;
}

/* ---------- Header: mark left, links centred, outlined pill right, hairline under ---------- */

.sc-header {
  position: sticky;
  top: 0;
  z-index: 50;
  /* a pill as wide as the content column, its bottom corners rounded, as on the rest of the site */
  margin-inline: auto;
  width: calc(min(100%, var(--maxw)) - 2 * var(--gutter));
  min-width: max-content;
  max-width: 100%;
  min-height: var(--nav-h);
  display: flex;
  align-items: center;
  background: var(--paper);
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 24px 24px;
}

/* once the page scrolls: a soft shadow under the pill (scroll-driven, where supported) */
@supports (animation-timeline: scroll()) {
  .sc-header {
    animation: sc-lift linear both;
    animation-timeline: scroll(root block);
    animation-range: 0 24px;
  }
  @keyframes sc-lift {
    to {
      background: hsl(0 0% 100% / 0.97);
      box-shadow: 0 10px 24px -14px rgba(28, 32, 70, 0.22);
    }
  }
}

.sc-bar {
  width: 100%;
  padding: 14px clamp(16px, 2.2vw, 32px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px clamp(24px, 3vw, 48px);
}

.sc-logo {
  justify-self: start;
  display: flex;
  padding: 8px 0;
}

.sc-links {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 4px 40px;
}

.sc-link,
.sc-links summary {
  position: relative;
  display: block;
  padding: 10px 0;
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
  transition: color 0.2s var(--ease-soft);
}
.sc-links summary::-webkit-details-marker {
  display: none;
}
@media (hover: hover) and (pointer: fine) {
  .sc-link:hover,
  .sc-links summary:hover,
  .sc-cta:hover {
    color: var(--ink-3);
  }
}
.sc-link[aria-current]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 6px;
  height: 1px;
  background: currentColor;
}

/* Product: a small menu under the link */
.sc-drop {
  position: relative;
}
.sc-drop ul {
  position: absolute;
  top: calc(100% + 8px);
  left: -16px;
  min-width: 240px;
  padding: 8px;
  display: grid;
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--ink);
}
.sc-drop ul a {
  display: block;
  padding: 10px 12px;
  font-size: 0.9375rem;
  line-height: 1.55;
  white-space: nowrap;
  transition: background-color 0.2s var(--ease-soft);
}
.sc-drop ul a:hover,
.sc-drop ul a[aria-current] {
  background: var(--paper-2);
}

.sc-end {
  grid-column: 3;
  justify-self: end;
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.2vw, 20px);
}

.sc-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 11px 20px;
  border: 1px solid var(--ink);
  border-radius: var(--radius-button);
  font-size: 0.9375rem;
  line-height: 1.55;
  white-space: nowrap;
  color: var(--ink);
  transition:
    color var(--dur-hover) ease,
    transform var(--dur-press) var(--ease-out);
}
.sc-cta svg {
  transition: transform var(--dur-hover) var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .sc-cta:hover svg {
    transform: translateX(3px);
  }
}
.sc-cta:focus-visible svg {
  transform: translateX(3px);
}
.sc-cta:active,
.sc-menu summary:active {
  transform: scale(0.97);
}

/* Phone: the links fold into a full-screen paper menu behind a three-bar toggle */
.sc-menu {
  display: none;
}
.sc-menu summary {
  width: 48px;
  height: 48px;
  margin-right: -10px;
  display: grid;
  place-items: center;
  cursor: pointer;
  list-style: none;
  transition: transform var(--dur-press) var(--ease-out);
}
.sc-menu summary::-webkit-details-marker {
  display: none;
}
.sc-bars {
  position: relative;
  width: 30px;
  height: 14px;
}
.sc-bars i {
  position: absolute;
  left: 0;
  width: 100%;
  height: 1.25px;
  background: currentColor;
  transition: transform 300ms var(--ease-out), opacity var(--dur-hover) ease;
}
.sc-bars i:nth-child(2) {
  top: 6.4px;
}
.sc-bars i:nth-child(3) {
  top: 12.75px;
}
.sc-menu[open] .sc-bars i:nth-child(1) {
  transform: translateY(6.4px) rotate(45deg);
}
.sc-menu[open] .sc-bars i:nth-child(2) {
  opacity: 0;
}
.sc-menu[open] .sc-bars i:nth-child(3) {
  transform: translateY(-6.35px) rotate(-45deg);
}
.sc-panel {
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  overflow-y: auto;
  padding: 24px var(--gutter) 48px;
  background: var(--paper);
  border-top: 1px solid var(--line);
}
.sc-panel p {
  margin: 28px 0 6px;
  font-family: var(--font-instrument);
  font-size: var(--fs-label);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--ink-3);
}
.sc-panel li {
  border-bottom: 1px solid var(--line);
}
.sc-panel a {
  display: block;
  padding-block: 10px;
  font-family: var(--font-serif);
  font-size: 1.75rem;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

@media (max-width: 900px) {
  /* phones: a full-width bar, as on the rest of the site */
  .sc-header {
    width: auto;
    min-width: 0;
    border-inline: 0;
    border-radius: 0;
  }
  .sc-bar {
    grid-template-columns: auto 0 auto;
  }
  .sc-links {
    display: none;
  }
  .sc-menu {
    display: block;
  }
}
@media (max-width: 420px) {
  .sc-cta {
    padding: 9px 14px;
    font-size: 0.875rem;
  }
}

/* ---------- Footer: wordmark, link columns, the dictionary entry, base row ---------- */

.sc-footer {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(64px, 6vw, 120px) var(--gutter) clamp(28px, 3vw, 44px);
  background: var(--paper);
  font-family: var(--font-instrument);
  font-size: 0.8125rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.sc-wordmark {
  margin: clamp(28px, 3.2vw, 56px) 0 clamp(36px, 3.6vw, 64px);
  font-family: var(--font-serif);
  font-weight: 370;
  font-variation-settings: "opsz" 72;
  /* the Home wordmark is fitted to the column by script; this is its no-script size */
  font-size: min(13.4vw, 194px);
  overflow: hidden;
  line-height: 1.06;
  letter-spacing: var(--tracking-display);
  text-transform: none;
  white-space: nowrap;
}

.sc-cols {
  display: grid;
  grid-template-columns: repeat(4, auto) 1fr;
  gap: clamp(24px, 3.6vw, 56px);
}

.sc-col {
  display: grid;
  align-content: start;
  gap: 18px;
}

.sc-col-title {
  margin: 0;
  font-weight: 500;
  font-size: 0.9375rem;
  letter-spacing: 0.2em;
}

.sc-list {
  display: grid;
  gap: 4px;
  font-style: normal;
  line-height: 1.55;
  color: var(--ink-2);
}

.sc-footer .sc-list a {
  position: relative;
  display: inline-block;
  padding-block: 3px;
}
.sc-footer .sc-list a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 1px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: 100% 50%;
  transition: transform 250ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .sc-footer .sc-list a:hover::after {
    transform: scaleX(1);
    transform-origin: 0 50%;
  }
}

.sc-def {
  justify-self: end;
  max-width: 24ch;
  margin: 0;
  font-family: var(--font-sans);
  text-transform: none;
  letter-spacing: 0;
}
.sc-def dfn {
  font-style: normal;
  font-size: 1rem;
  font-weight: 500;
}
.sc-def dt span {
  font-style: italic;
  font-size: 0.875rem;
  color: var(--ink-3);
}
.sc-def dd {
  margin: 8px 0 0;
  font-style: italic;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: var(--ink-3);
}

.sc-base {
  margin-top: clamp(56px, 6vw, 96px);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 32px;
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  color: var(--ink-3);
}
.sc-base p {
  margin: 0;
}
.sc-base nav {
  display: flex;
  gap: 24px;
}

@media (max-width: 1000px) {
  .sc-cols {
    grid-template-columns: 1fr 1fr;
    row-gap: 40px;
  }
  .sc-def {
    justify-self: start;
  }
}
@media (max-width: 520px) {
  .sc-cols {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  .sc-header *,
  .sc-footer * {
    transition: none !important;
  }
}

.sc-vh {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
