/* Slides as web pages: one slide per screen, no JS (CSP). Boxes and
   corners come from style.css (.diagram, .d-box). */

html.slides-page {
  /* Everything in rem grows with the screen, so slides fill a shared screen. */
  font-size: clamp(15px, min(1.45vw, 2.45vh), 30px);
}

.slides-page body {
  font-size: 1rem;
}

.slides {
  display: block;
}

.slide {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: min(100%, 72rem);
  margin: 0 auto;
  padding: 2.5rem 16px 1.5rem;
  border-bottom: 1px solid var(--border);
}

.slide h1 {
  font-size: clamp(2.1rem, 9vw, 5.4rem);
}

.slide h2 {
  margin: 0;
  font-size: clamp(1.5rem, 7vw, 2.4rem);
}

.s-eyebrow {
  margin: 0;
  color: var(--cyan);
  font-size: 1rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.s-intro {
  margin: 0;
  color: var(--text-soft);
  font-size: 1.15rem;
}

.s-lead {
  max-width: 46rem;
  margin: 0;
  color: var(--text-soft);
  font-size: 1.4rem;
  line-height: 1.35;
}

.s-body {
  min-width: 0;
}

.s-body .diagram {
  width: 100%;
  margin: 0;
}

.s-foot {
  margin: 0;
  color: var(--text-soft);
  font-size: 1rem;
  line-height: 1.45;
}

.s-nav,
.s-links {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.s-links {
  justify-content: flex-start;
  font-size: 1rem;
}

.s-next {
  color: var(--cyan);
  text-decoration: none;
}

/* Building blocks and reasoner: card grid */
.s-cards {
  display: grid;
  gap: 1rem;
}

.s-cards .d-box {
  display: grid;
  gap: 0.4rem;
  padding: 1rem 1.25rem;
}

.s-cards p {
  margin: 0;
}

.s-cards .d-title {
  font-size: 1.2rem;
}

.s-cards .d-text {
  font-size: 1rem;
}

/* RDF table */
.s-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 1rem;
}

.s-table th,
.s-table td {
  padding: 0.45rem 0.75rem 0.45rem 0;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

.s-table th {
  color: var(--muted);
  font-weight: 600;
}

.s-table td:first-child {
  font-weight: 600;
}

.s-table code {
  color: var(--violet-text);
  font-family: var(--mono);
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}

@media (min-width: 760px) {
  .s-cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Wide and landscape: one slide per screen, scrolling snaps. */
@media (min-width: 900px) and (min-aspect-ratio: 4/3) {
  html.slides-page {
    scroll-snap-type: y proximity;
  }

  .slide {
    justify-content: center;
    min-height: 100vh;
    padding: 2rem max(16px, 3vw);
    scroll-snap-align: start;
    border-bottom: 0;
  }

  .s-cover {
    gap: 1.5rem;
  }

  .slide .s-nav {
    margin-top: auto;
  }

  .slide h2 + .s-body {
    margin-top: 0.5rem;
  }

  .slides-page footer {
    scroll-snap-align: end;
  }

  /* The chat is the tallest slide. */
  .s-fit .s-body {
    zoom: 0.72;
  }
}
