/* Version C: switchboard */

.c-board {
  padding-top: calc(var(--nav-h) + clamp(16px, 2.4vw, 32px));
}

/* The explorer fits one screen, so the title stays on one line */
.c-board h1 {
  font-size: clamp(2.25rem, 3.6vw, 3.25rem);
  line-height: 1;
  letter-spacing: -0.035em;
}

.c-tabs {
  display: flex;
  gap: clamp(20px, 3vw, 44px);
  margin-top: clamp(16px, 2vw, 28px);
  border-bottom: 1px solid var(--rule-ink);
}

.c-tabs button {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  min-height: 52px;
  padding: 12px 0;
  border: 0;
  background: none;
  color: var(--ink-2);
  font: inherit;
  font-size: clamp(1.0625rem, 1.3vw, 1.25rem);
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: color 0.2s ease-out;
}

.c-tabs button::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.c-tabs button:hover,
.c-tabs button[aria-selected="true"] {
  color: var(--ink);
}

.c-tabs button[aria-selected="true"]::after {
  transform: none;
}

.c-n {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--ink-3);
}

.c-short {
  display: none;
}

.c-intro {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}

.c-q {
  font-size: clamp(1.25rem, 1.6vw, 1.5rem);
  line-height: 1.25;
  font-weight: 600;
  letter-spacing: -0.015em;
}

.c-intro p + p {
  max-width: 40ch;
  font-size: 0.9375rem;
  color: var(--ink-2);
}

.c-body {
  display: grid;
  grid-template-columns: minmax(0, 20rem) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 80px);
  padding-top: clamp(20px, 2.4vw, 28px);
}

/* The homepage's step rail */
.c-list {
  position: relative;
  align-self: start;
  margin: 0;
  padding: 0;
  list-style: none;
}

.c-list::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 22px;
  bottom: 22px;
  width: 1px;
  background: var(--rule-ink);
}

.c-list button {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 44px;
  padding: 8px 0 8px 30px;
  border: 0;
  background: none;
  color: var(--ink-2);
  font: inherit;
  font-weight: 500;
  line-height: 1.3;
  text-align: left;
  cursor: pointer;
}

.c-list button::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 11px;
  height: 11px;
  margin-top: -5.5px;
  border-radius: 50%;
  background: var(--dot);
  box-shadow: 0 0 0 4px var(--paper);
  transition:
    background-color 0.2s ease-out,
    transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.c-list button:hover {
  color: var(--ink);
}

.c-list button[aria-expanded="true"] {
  color: var(--ink);
  font-weight: 700;
}

.c-list button[aria-expanded="true"]::before {
  background: var(--accent);
  transform: scale(1.35);
}

/* Diagram on top, the use case and its call to action side by side under it, all inside the viewport */
.c-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "fig fig" "copy actions";
  gap: 16px clamp(28px, 3.6vw, 56px);
  align-content: start;
}

.c-fig {
  grid-area: fig;
  position: relative;
}

.c-fig canvas {
  display: block;
  width: 100%;
  height: clamp(220px, calc(100svh - 480px), 400px);
}

.c-fig .source {
  position: absolute;
  left: 0;
  bottom: 0;
}

.c-copy {
  grid-area: copy;
}

.c-detail h2 {
  max-width: 26ch;
  font-size: clamp(1.375rem, 1.8vw, 1.75rem);
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.c-desc {
  max-width: 52ch;
  margin-top: 8px;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--ink-2);
}

.c-actions {
  grid-area: actions;
  display: grid;
  justify-items: start;
  align-content: start;
  gap: 16px;
  max-width: 17rem;
}

@media (max-width: 991px) {
  .c-body {
    grid-template-columns: minmax(0, 15rem) minmax(0, 1fr);
  }
}

@media (max-width: 767px) {
  .c-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }

  .c-tabs button {
    font-size: 1rem;
  }

  .c-long {
    display: none;
  }

  .c-short {
    display: inline;
  }

  .c-body {
    grid-template-columns: minmax(0, 1fr);
  }

  .c-body {
    gap: 0;
  }

  .c-list::before {
    bottom: 28px;
  }

  .c-detail {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "fig" "copy" "actions";
    padding: 4px 0 28px 30px;
  }

  .c-fig canvas {
    height: auto;
    aspect-ratio: 4 / 3;
  }

  .c-fig .source {
    position: static;
    margin-top: 6px;
  }

  .c-actions {
    max-width: none;
  }

  .c-detail h2 {
    display: none;
  }

  .c-desc {
    margin-top: 8px;
    font-size: 1rem;
  }

  .c-actions {
    gap: 16px;
  }
}
