/* AI-native company doc. Same look as the /resources hub (resources.css): white canvas, system type, quiet colour.
   The navbar is styled by site-nav.css. ai-native.js reads #doc, .doc-frame (+ .open), .copy-toast (+ .visible),
   [data-copy-doc] (+ .copied) and [data-expand-doc]: keep those hooks. */

:root {
  color-scheme: light;
  --bg: #ffffff;
  --bg-soft: #f5f5f7;
  --card: #ffffff;
  --ink: #1d1d1f;
  --ink-soft: #6e6e73;
  --ink-faint: #86868b;
  --line: #d2d2d7;
  --hair: rgba(0, 0, 0, 0.08);
  --accent: #0071e3;
  --accent-ink: #0066cc;
  --radius: 24px;
  --ease: cubic-bezier(0.28, 0.11, 0.32, 1);
  --maxw: 1040px;
  --gutter: max(clamp(20px, 5vw, 40px), calc((100% - var(--maxw)) / 2));
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Inter", "Helvetica Neue", "Segoe UI", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  min-width: 280px;
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.47 var(--font);
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

a:focus-visible,
button:focus-visible,
pre:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--font);
  text-wrap: balance;
}

p {
  margin: 0;
}

.paper {
  display: none;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 16px;
  border-radius: 980px;
  background: var(--ink);
  color: #fff;
  font-size: 14px;
  text-decoration: none;
  transform: translateY(-180%);
  transition: transform 0.2s var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

/* Kickers and section heads */
.eyebrow,
.section-label {
  color: var(--ink-soft);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

article > section {
  padding: clamp(56px, 8vw, 104px) var(--gutter);
}

article > section:nth-of-type(odd) {
  background: var(--bg-soft);
}

h2 {
  max-width: 760px;
  margin-top: 8px;
  font-size: clamp(34px, 5.4vw, 56px);
  font-weight: 700;
  line-height: 1.07;
  letter-spacing: -0.03em;
}

.section-intro {
  max-width: 720px;
  margin-top: 14px;
  color: var(--ink-soft);
  font-size: clamp(18px, 2vw, 21px);
  line-height: 1.4;
}

code {
  font-family: var(--mono);
}

.section-intro code,
.steps code {
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--bg-soft);
  color: var(--ink);
  font-size: 0.86em;
  overflow-wrap: anywhere;
}

/* Hero */
.hero {
  padding: clamp(64px, 11vw, 132px) var(--gutter) clamp(48px, 7vw, 84px);
  text-align: center;
}

.hero h1 {
  max-width: 17ch;
  margin: 14px auto 0;
  font-size: clamp(42px, 7.6vw, 88px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.035em;
}

.hero h1 em {
  font-style: normal;
}

.lede {
  max-width: 700px;
  margin: 22px auto 0;
  color: var(--ink-soft);
  font-size: clamp(18px, 2.1vw, 21px);
  line-height: 1.42;
  letter-spacing: -0.012em;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 14px 26px;
  margin-top: 30px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border: 0;
  border-radius: 980px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-size: 17px;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s;
}

.btn:hover {
  background: #0077ed;
}

.btn.ghost {
  padding: 12px 0;
  border-radius: 6px;
  background: none;
  color: var(--accent-ink);
}

.btn.ghost:hover {
  background: none;
  text-decoration: underline;
}

a.btn.ghost::after {
  content: "\203A";
}

.btn.copied {
  background: var(--ink);
}

.meta {
  margin-top: 20px;
  color: var(--ink-faint);
  font-size: 14px;
}

/* Steps: white cards on the grey band */
.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 1.8vw, 22px);
  margin: clamp(28px, 4vw, 48px) 0 0;
  padding: 0;
  list-style: none;
}

.steps li {
  padding: 26px;
  border-radius: var(--radius);
  background: var(--card);
}

.step-no {
  display: block;
  color: var(--ink-faint);
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.steps h3 {
  margin-top: 10px;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.022em;
}

.steps p {
  margin-top: 8px;
  color: var(--ink-soft);
  font-size: 16px;
  line-height: 1.42;
}

/* The line to send to the agent */
.say {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 16px;
  margin-top: clamp(14px, 1.8vw, 22px);
  padding: 20px 26px;
  border-radius: 18px;
  background: var(--card);
}

.say span {
  color: var(--ink-soft);
  font-size: 15px;
}

.say code {
  flex: 1 1 16rem;
  font-size: 15px;
  overflow-wrap: anywhere;
}

/* The document */
.doc-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 18px 24px;
}

.doc-frame {
  position: relative;
  margin-top: clamp(28px, 4vw, 48px);
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--bg-soft);
}

.doc-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 24px;
  border-bottom: 1px solid var(--hair);
  color: var(--ink-soft);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0;
}

.doc-bar .btn {
  padding: 6px 0;
  font-family: var(--font);
  font-size: 14px;
}

#doc {
  max-height: 34rem;
  margin: 0;
  padding: 22px 24px 64px;
  overflow: auto;
  color: var(--ink);
  font-family: var(--mono);
  font-size: 13.5px;
  line-height: 1.65;
  letter-spacing: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  tab-size: 2;
  transition: max-height 0.35s var(--ease);
}

#doc:focus-visible {
  outline-offset: -3px;
}

.doc-frame.open #doc {
  max-height: 120rem;
  padding-bottom: 24px;
}

.doc-fade {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  justify-content: center;
  padding: 64px 16px 18px;
  background: linear-gradient(to bottom, rgba(245, 245, 247, 0), var(--bg-soft) 68%);
  pointer-events: none;
}

.doc-fade .btn {
  padding: 10px 20px;
  border-radius: 980px;
  background: var(--card);
  box-shadow: 0 0 0 1px var(--hair);
  font-size: 15px;
  pointer-events: auto;
}

.doc-fade .btn:hover {
  background: var(--card);
}

.doc-frame.open .doc-fade {
  display: none;
}

/* Sources */
.sources-list {
  display: grid;
  gap: 12px;
  margin: clamp(28px, 4vw, 48px) 0 0;
  padding: 0;
  list-style: none;
}

.sources-list a {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 28px;
  padding: 20px 26px;
  border-radius: 18px;
  background: var(--card);
  text-decoration: none;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

.sources-list a:hover {
  box-shadow: 0 18px 36px -24px rgba(0, 0, 0, 0.28);
  transform: translateY(-2px);
}

.sources-list strong {
  flex: 1 1 22rem;
  font-size: 19px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
}

.sources-list a:hover strong {
  color: var(--accent-ink);
}

.sources-list em {
  color: var(--ink-soft);
  font-size: 15px;
  font-style: normal;
}

/* Closing statement: the black band */
.closing {
  padding: clamp(64px, 10vw, 120px) var(--gutter);
  background: #000;
  color: #f5f5f7;
  text-align: center;
}

.closing .eyebrow {
  color: #a1a1a6;
  font-size: clamp(18px, 2vw, 21px);
  font-weight: 400;
}

.closing strong {
  display: block;
  max-width: 18ch;
  margin: 12px auto 0;
  font-size: clamp(34px, 6vw, 64px);
  font-weight: 700;
  line-height: 1.07;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.closing .btn {
  margin-top: 32px;
}

.copy-toast {
  position: fixed;
  z-index: 90;
  bottom: 24px;
  left: 50%;
  width: max-content;
  max-width: calc(100% - 32px);
  padding: 12px 20px;
  border-radius: 980px;
  background: rgba(29, 29, 31, 0.94);
  color: #fff;
  font-size: 15px;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 12px);
  transition: opacity 0.2s, transform 0.2s var(--ease);
}

.copy-toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 22px var(--gutter) 40px;
  color: var(--ink-soft);
  font-size: 13px;
}

footer a {
  color: var(--accent-ink);
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

@media (max-width: 760px) {
  body {
    font-size: 16px;
  }

  .steps {
    grid-template-columns: 1fr;
  }

  .say {
    padding: 18px 22px;
  }

  .doc-bar {
    padding-inline: 18px;
  }

  #doc {
    max-height: 26rem;
    padding: 18px 18px 64px;
    font-size: 12.5px;
  }

  .sources-list a {
    padding: 18px 22px;
  }

  footer {
    flex-direction: column;
  }
}

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

  *,
  *::before,
  *::after {
    transition: none !important;
  }

  .sources-list a:hover {
    transform: none;
  }
}
