/* The inner pages — Features and How it works. They wear the home page's
   chrome and tokens (home.css, loaded first); this file holds only what the
   home page has no equivalent of: the page title, the tutorial's lessons, and
   the feature cards. */

html { scroll-padding-top: 110px; }

/* ---------- page title --------------------------------------------------- */

.page-title { padding: 90px 0 64px; border-bottom: 1px solid var(--line); margin-bottom: 64px; }
.page-title h1 {
  font-size: clamp(54px, 8vw, 106px);
  font-weight: 500;
  letter-spacing: -0.065em;
  line-height: 1;
  margin: 0 0 22px;
}
.page-title p { font-size: 19px; }
.page-title a.inline { color: var(--ink); border-bottom: 1px solid var(--line); }
.page-title a.inline:hover { color: var(--blue-soft); border-color: var(--blue-soft); }

kbd {
  font: 11px var(--mono);
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-2);
  padding: 3px 6px;
  color: var(--ink);
}

/* ---------- tutorial ------------------------------------------------------ */

.tutorial { display: grid; grid-template-columns: 235px minmax(0, 1fr); gap: 80px; }
.toc {
  position: sticky;
  top: 32px;
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 2px;
  counter-reset: toc;
}
.toc a {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--muted);
  font-size: 14px;
  counter-increment: toc;
  transition: background 0.2s, color 0.2s;
}
.toc a::before { content: counter(toc, decimal-leading-zero); font: 10px var(--mono); color: var(--faint); }
.toc a:hover { color: var(--ink); background: var(--surface); }
.toc a.current { color: var(--blue-soft); background: var(--blue-dim); }
.toc a.current::before { color: var(--blue); }

.lesson { padding-bottom: 64px; margin-bottom: 60px; border-bottom: 1px solid var(--line); scroll-margin-top: 36px; }
.lesson:last-child { border-bottom: 0; margin-bottom: 0; }
.lesson h2 { font-size: clamp(32px, 3.2vw, 44px); margin-bottom: 20px; }
.lesson p { max-width: 690px; }

.clip {
  margin-top: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  aspect-ratio: 1400 / 868;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.clip video { width: 100%; height: 100%; display: block; }
.placeholder { display: flex; flex-direction: column; align-items: center; gap: 18px; color: var(--muted); font: 11px var(--mono); }
.placeholder .dot {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--blue);
}

/* ---------- features ------------------------------------------------------ */

.fgroup { padding-bottom: 64px; margin-bottom: 60px; border-bottom: 1px solid var(--line); }
.fgroup:last-child { border-bottom: 0; margin-bottom: 0; }
.fgroup .eyebrow { margin-bottom: 14px; }
.fgroup h2 { font-size: clamp(32px, 3.2vw, 44px); margin-bottom: 30px; }
.fgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.fcard {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  transition: border-color 0.2s, transform 0.2s;
}
.fcard:hover { border-color: #33343b; transform: translateY(-2px); }
.fcard h3 { font-size: 19px; font-weight: 600; letter-spacing: -0.02em; margin: 0; }
.fcard p { font-size: 15px; line-height: 1.55; }
.fcard kbd { font-size: 10px; }
.fmore { margin-top: auto; padding-top: 8px; font: 11px var(--mono); color: var(--blue); }
.fmore:hover { color: var(--blue-soft); }

/* ---------- responsive ---------------------------------------------------- */

@media (max-width: 1000px) {
  .tutorial { gap: 36px; grid-template-columns: 190px minmax(0, 1fr); }
  .fgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .page-title { padding: 60px 0 32px; margin-bottom: 32px; }
  .page-title p { font-size: 16px; }
  .tutorial { grid-template-columns: 1fr; gap: 38px; }
  .toc { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; }
  .toc a { font-size: 12px; gap: 8px; padding: 8px 10px; }
  .lesson, .fgroup { padding-bottom: 40px; margin-bottom: 40px; }
  .lesson h2, .fgroup h2 { font-size: 30px; }
  .lesson p { font-size: 16px; }
  .clip { margin-top: 20px; }
  .fgrid { grid-template-columns: 1fr; gap: 12px; }
  .fcard { padding: 22px 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .fcard, .toc a { transition: none; }
  .fcard:hover { transform: none; }
}
