/* Long-form guide pages (/he/ai-workers-guide-article). Loaded after /styles.css and uses its tokens. */

.guide-wrap { max-width: calc(720px + 2 * var(--gutter)); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Head of the article */
.guide-head { padding-top: 64px; }
.guide-head h1 { margin-top: 12px; font-size: 42px; line-height: 52px; font-weight: 800; letter-spacing: -0.5px; }
.h1-en { display: block; margin-bottom: 6px; color: var(--ink-muted); font-size: 0.62em; line-height: 1.3; letter-spacing: 0; }
.guide-sub { margin-top: 16px; font-size: 20px; line-height: 32px; color: var(--ink-muted); }
.byline { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--border); display: flex; align-items: center; gap: 14px; }
.byline img { width: 52px; height: 52px; border-radius: 9999px; object-fit: cover; background: var(--grad-m); }
.byline-name { font-size: 16px; line-height: 24px; font-weight: 700; }
.byline-name a { text-decoration: none; }
.byline-name a:hover { text-decoration: underline; text-decoration-color: var(--amber); text-underline-offset: 4px; }
.byline-date { font-size: 14px; line-height: 20px; color: var(--ink-muted); }

/* The recorded guide */
.video { margin: 32px 0 0; }
.video-card {
  display: flex; align-items: center; gap: 18px; padding: 20px 24px; border-radius: 20px;
  background: var(--navy); color: var(--off-white); text-decoration: none;
  box-shadow: 0 18px 40px -26px #15233fb3; transition: transform .15s ease;
}
.video-card:hover { color: var(--off-white); transform: translateY(-1px); }
.guide article a.video-card, .guide article a.video-card:hover { color: var(--off-white); text-decoration: none; font-weight: 400; }
.video-play { flex: none; width: 56px; height: 56px; border-radius: 9999px; background: var(--grad-head); color: var(--on-amber); display: flex; align-items: center; justify-content: center; box-shadow: inset 0 -3px 6px #15233f40; }
.video-play svg { transform: scaleX(-1); }
.video-text { display: flex; flex-direction: column; gap: 2px; }
.guide article .video-text strong { font-size: 18px; line-height: 26px; color: var(--off-white); }
.video-text span { font-size: 15px; line-height: 22px; color: var(--muted-on-dark); }
.video-frame { position: relative; aspect-ratio: 16 / 9; border-radius: 20px; overflow: hidden; background: var(--navy); }
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Author box and table of contents */
.author-box, .toc { margin-top: 32px; padding: 24px 28px; border-radius: 20px; border: 1px solid var(--border); background: #fff; }
.guide article .author-box h2, .guide article .toc h2 { font-size: 18px; line-height: 26px; font-weight: 800; }
.guide article .author-box p { margin-top: 10px; font-size: 16px; line-height: 27px; color: var(--ink-muted); }
.toc ol { margin: 12px 0 0; padding-inline-start: 24px; display: grid; gap: 6px; font-size: 16px; line-height: 26px; }
.toc li::marker { color: var(--ink-muted); font-weight: 700; }
.toc a { font-weight: 600; text-decoration: underline; text-decoration-color: #f4ad42aa; text-decoration-thickness: 2px; text-underline-offset: 5px; }
.toc a:hover { text-decoration-color: var(--amber); }

/* Body text */
.guide article section { margin-top: 72px; padding-top: 48px; border-top: 1px solid var(--border); }
.guide article section:last-of-type { padding-bottom: 24px; }
.guide article h2 { font-size: 34px; line-height: 42px; font-weight: 800; letter-spacing: -0.4px; }
.guide article h3 { margin-top: 48px; font-size: 25px; line-height: 34px; font-weight: 800; letter-spacing: -0.2px; }
.guide article h4, .guide article h5 { margin: 0; }
.guide article h4 { margin-top: 28px; font-size: 19px; line-height: 28px; font-weight: 800; }
.guide article h4.sub-head { margin-top: 48px; font-size: 23px; line-height: 32px; }
.guide article h5 { font-size: 20px; line-height: 28px; font-weight: 800; }
.guide article p { margin-top: 16px; font-size: 18px; line-height: 31px; color: var(--ink-muted); }
.guide article h2 + p, .guide article h3 + p, .guide article h4 + p { margin-top: 12px; }
.guide article strong { color: var(--ink); font-weight: 700; }
.guide article p.em { color: var(--ink); font-weight: 700; }
.guide article p.em.big { font-size: 22px; line-height: 34px; }
.guide article .u { text-decoration: underline; text-decoration-color: var(--amber); text-decoration-thickness: 2px; text-underline-offset: 5px; }
.guide article p.label { margin-top: 22px; font-size: 15px; line-height: 20px; font-weight: 800; letter-spacing: 0.3px; color: var(--ink); }
.guide article p.label + p, .guide article p.label + ul { margin-top: 6px; }
.guide article ul, .guide article ol { margin: 14px 0 0; padding-inline-start: 24px; display: grid; gap: 8px; font-size: 18px; line-height: 30px; color: var(--ink-muted); }
.guide article li::marker { color: #c97a12; }
.guide article a { color: var(--ink); font-weight: 700; text-decoration: underline; text-decoration-color: var(--amber); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.guide article .toc a { font-weight: 600; }

/* Callouts, cards, quotes */
.note { margin-top: 28px; padding: 24px 28px; border-radius: 20px; background: #f4ad421f; border: 1px solid #f4ad4266; }
.guide article .note > :first-child { margin-top: 0; }
.guide article .note p.note-title, .guide article .note h3 { font-size: 19px; line-height: 28px; font-weight: 800; color: var(--ink); }
.note-center { text-align: center; }
.card { margin-top: 24px; padding: 28px; border-radius: 20px; background: #fff; border: 1px solid var(--border); box-shadow: 0 10px 28px -22px #15233f59; }
.guide article .card > :first-child { margin-top: 0; }
.guide article .card .note { background: #f4ad4214; }
.pull { margin: 28px 0 0; padding: 4px 22px 4px 0; border-inline-start: 4px solid var(--amber); }
.guide article .pull p { margin-top: 0; font-size: 21px; line-height: 34px; font-weight: 600; color: var(--ink); }
.quote { margin: 14px 0 0; padding: 16px 20px; border-radius: 14px; background: var(--surface); border-inline-start: 4px solid var(--amber); }
.guide article .quote p { margin-top: 0; color: var(--ink); }
.guide article .tip { padding: 14px 18px; border-radius: 14px; background: #f4ad421f; border: 1px solid #f4ad4266; font-size: 17px; line-height: 28px; }

/* The four generations at a glance */
.guide article .gens { list-style: none; margin: 28px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.gens a { height: 100%; display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: 18px; background: #fff; border: 1px solid var(--border); text-decoration: none !important; transition: border-color .15s ease, transform .15s ease; }
.gens a:hover { border-color: var(--amber); transform: translateY(-1px); }
.gens .num { width: 44px; height: 44px; font-size: 18px; }
.gens a > span:last-child { display: flex; flex-direction: column; gap: 2px; }
.gens strong { font-size: 16px; line-height: 23px; font-weight: 800; }
.gens strong + span { font-size: 14px; line-height: 20px; font-weight: 500; color: var(--ink-muted); }

/* Illustrations: square drawings on white, framed so the white blends in */
.fig { margin: 28px auto 0; width: fit-content; max-width: 100%; border-radius: 24px; overflow: hidden; background: #fff; border: 1px solid var(--border); }
.fig img { width: 280px; height: auto; }
.fig-wide img { width: 440px; }
.fig-in { margin-top: 16px; border: 0; border-radius: 0; }
.fig-in img { width: 240px; }

/* Tools inside pillar 4 */
.tool-types { margin-top: 16px; display: grid; gap: 12px; }
.tool { padding: 18px 20px; border-radius: 16px; background: var(--surface); border: 1px solid var(--border); }
.guide article .tool p { margin-top: 8px; font-size: 16px; line-height: 27px; }
.guide article .tool ul { margin-top: 6px; font-size: 16px; line-height: 27px; gap: 4px; }

/* Formula and the cost calculation */
.guide article p.formula { margin-top: 14px; padding: 16px 18px; border-radius: 14px; background: var(--navy); color: var(--off-white); text-align: center; font-weight: 800; font-size: 19px; line-height: 30px; }
.calc { margin-top: 12px; width: 100%; border-collapse: collapse; font-size: 17px; line-height: 26px; }
.calc th, .calc td { padding: 10px 0; border-top: 1px solid #15233f1f; text-align: start; vertical-align: top; }
.calc tr:first-child th, .calc tr:first-child td { border-top: 0; }
.calc th { font-weight: 500; color: var(--ink-muted); padding-inline-end: 16px; }
.calc td { font-weight: 800; color: var(--ink); white-space: nowrap; text-align: end; }

/* The decision matrix */
.matrix { margin-top: 24px; width: 100%; border-collapse: separate; border-spacing: 0; border: 1px solid var(--border); border-radius: 20px; overflow: hidden; background: #fff; font-size: 16px; line-height: 25px; }
.matrix th, .matrix td { padding: 16px 18px; text-align: start; vertical-align: top; border-top: 1px solid var(--border); }
.matrix thead th { border-top: 0; background: var(--navy); color: var(--off-white); font-size: 14px; font-weight: 700; }
.matrix tbody th { font-weight: 800; color: var(--ink); white-space: nowrap; }
.matrix tbody td { color: var(--ink-muted); }
.matrix tbody tr:nth-child(even) { background: #f4ad420f; }

/* Options inside common scenarios */
.options { margin: 14px 0 0; display: grid; gap: 10px; }
.options > div { padding: 14px 18px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); }
.options dt { font-size: 16px; line-height: 24px; font-weight: 800; color: var(--ink); }
.options dd { margin: 4px 0 0; font-size: 17px; line-height: 28px; color: var(--ink-muted); }
.options dd span { display: block; margin-top: 2px; font-size: 16px; line-height: 26px; color: var(--ink-muted); opacity: .9; }

/* Check lists and the vision questions */
.guide article ul.checks { list-style: none; padding: 0; }
.checks li { position: relative; padding-inline-start: 30px; }
.checks li::before {
  content: ""; position: absolute; inset-inline-start: 0; top: 7px; width: 18px; height: 18px; border-radius: 9999px;
  background: var(--grad-head) ; box-shadow: inset 0 -2px 3px #15233f33;
}
.checks li::after {
  content: ""; position: absolute; inset-inline-start: 6px; top: 11px; width: 5px; height: 8px;
  border: solid var(--navy); border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.guide article ul.questions { list-style: none; padding: 0; margin-top: 18px; gap: 12px; }
.questions li { padding: 16px 20px; border-radius: 16px; background: #fff; border: 1px solid var(--border); border-inline-start: 4px solid var(--amber); font-size: 19px; line-height: 30px; font-weight: 600; color: var(--ink); }

/* The five first steps */
.guide article ol.steps-list { list-style: none; padding: 0; margin-top: 8px; gap: 0; }
.steps-list > li.card { margin-top: 20px; }
.guide article .steps-list h3 { margin-top: 0; display: flex; align-items: center; gap: 14px; font-size: 22px; line-height: 30px; }
.steps-list .num { width: 44px; height: 44px; font-size: 18px; }
.guide article .steps-list ol { list-style: decimal; }
.guide article .steps-list ul { list-style: disc; }

/* End of the article: discovery call and newsletter */
.guide-cta .wrap { padding-block: 72px 104px; }
.guide-cta .team-cta-card .eyebrow { color: var(--on-amber); }
.guide-cta .team-cta-card h2 { font-size: 32px; line-height: 40px; }
.nl-strip { margin-top: 20px; padding: 24px 28px; border-radius: 24px; border: 1px solid var(--border); background: #fff; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.nl-strip-title { font-size: 18px; line-height: 26px; font-weight: 800; }
.nl-strip p:not(.nl-strip-title) { margin-top: 4px; font-size: 16px; line-height: 26px; color: var(--ink-muted); }
.nl-strip .btn { flex: none; }

@media (prefers-reduced-motion: reduce) { .video-card, .gens a { transition: none; } }

/* Phone */
@media (max-width: 720px) {
  .guide-head { padding-top: 36px; }
  .guide-head h1 { font-size: 30px; line-height: 38px; letter-spacing: -0.3px; }
  .guide-sub { font-size: 18px; line-height: 28px; }
  .video-card { padding: 16px 18px; gap: 14px; }
  .video-play { width: 48px; height: 48px; }
  .author-box, .toc { padding: 20px; }
  .guide article section { margin-top: 48px; padding-top: 36px; }
  .guide article h2 { font-size: 27px; line-height: 35px; }
  .guide article h3 { margin-top: 40px; font-size: 22px; line-height: 30px; }
  .guide article h4.sub-head { font-size: 21px; line-height: 29px; }
  .guide article h5 { font-size: 19px; line-height: 27px; }
  .guide article p, .guide article ul, .guide article ol { font-size: 17px; line-height: 29px; }
  .guide article .gens { grid-template-columns: 1fr; }
  .card { padding: 22px 18px; }
  .note { padding: 20px 18px; }
  .fig img { width: 240px; }
  .fig-wide img { width: 320px; }
  .fig-in img { width: 220px; }
  .guide article .pull p { font-size: 19px; line-height: 31px; }
  .questions li { font-size: 17px; line-height: 28px; }
  .calc { font-size: 16px; }
  .calc td { white-space: normal; }

  /* The matrix stacks: one card per row, the column name above each value */
  .matrix, .matrix tbody, .matrix tr, .matrix th, .matrix td { display: block; }
  .matrix thead { display: none; }
  .matrix { border: 0; background: none; border-radius: 0; overflow: visible; }
  .matrix tbody { display: grid; gap: 12px; }
  .matrix tbody tr { border: 1px solid var(--border); border-radius: 16px; background: #fff; padding: 6px 16px; }
  .matrix tbody tr:nth-child(even) { background: #fff; }
  .matrix tbody th, .matrix tbody td { padding: 10px 0; white-space: normal; }
  .matrix tbody tr > :first-child { border-top: 0; }
  .matrix tbody [data-label]::before { content: attr(data-label); display: block; font-size: 12px; line-height: 18px; font-weight: 700; letter-spacing: 0.3px; color: var(--ink-muted); }
  .matrix tbody th { font-size: 17px; }

  .guide-cta .wrap { padding-inline: 16px; padding-block: 48px 56px; }
  .guide-cta .team-cta-card h2 { font-size: 26px; line-height: 34px; }
  .nl-strip { flex-direction: column; align-items: stretch; padding: 22px 20px; }
  .nl-strip .btn { width: 100%; }
}
