@import url("./base.css?v=2489e8d30102");
:root {
  --paper: #f5f7f4;
  --ink: #26332b;
  --accent: #8a4a24;
  --rule: #c9d0c8;
  --muted: #536257;
}
html {
  scrollbar-gutter: stable;
}
body {
  font:
    1rem/1.55 Arial,
    sans-serif;
  min-width: 0;
}
.workshop-top,
main,
.site-footer,
.announcement,
.top-ad-boundary {
  max-width: 1140px;
  margin-inline: auto;
  padding-inline: 20px;
}
main {
  padding-top: 0;
}
a {
  color: inherit;
}
.workshop-top#top {
  display: block;
  padding-block: 0;
  border-bottom: 1px solid var(--rule);
}
.workshop-masthead {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  font-size: 1.15rem;
  line-height: 1.2;
  font-weight: 700;
  text-decoration: none;
  min-width: 0;
}
.brand-mark {
  font-size: 24px;
  color: var(--accent);
  line-height: 1;
}
.discovery-open {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  padding: 0 5px;
  border: 0;
  border-radius: 0;
  flex-shrink: 0;
  font-size: 0.9rem;
}
.discovery-open svg {
  flex: none;
  display: block;
}
header[id="top"] > nav {
  display: flex;
  gap: 22px;
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
  margin: 0;
  padding: 0;
  max-width: 100%;
}
header[id="top"] > nav::-webkit-scrollbar {
  display: none;
}
header[id="top"] > nav > a {
  display: inline-flex;
  align-items: center;
  flex: none;
  min-height: 44px;
  min-width: 44px;
  font-size: 0.9rem;
  padding: 0 1px;
  text-decoration: none;
}
header[id="top"] > nav > a > span {
  position: relative;
  padding-block: 2px;
}
header[id="top"] > nav > a[aria-current] > span::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent);
}
header[id="top"] > nav > a:hover {
  color: var(--accent);
}
.announcement {
  font-size: 0.9rem;
  margin-block: 8px;
}
.top-ad-boundary {
  display: flow-root;
  padding: 0;
}
.page-label {
  font-size: 0.95rem;
  margin: 0 0 8px;
  line-height: 1.45;
  font-weight: 400;
}
.section-heading {
  position: relative;
  min-height: 36px;
  padding-right: 100px;
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin: 0 0 4px;
}
.section-heading h2 {
  font-size: 1.05rem;
  line-height: 1.35;
  margin: 0;
  font-family: "Trebuchet MS", Arial, sans-serif;
}
.section-heading > a {
  position: absolute;
  right: 0;
  top: -4px;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 0.88rem;
  white-space: nowrap;
}
[data-module] {
  margin-bottom: 18px;
}
.module-ad-boundary:empty {
  display: none;
}
.workshop-grid {
  --discovery-columns: 2;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 18px;
  margin: 0;
  list-style: none;
  padding: 0;
}
.workshop-grid > li:nth-child(n) {
  min-width: 0;
  grid-column: auto;
  align-self: stretch;
  margin: 0;
}
.workshop-game > .game-link {
  display: block;
  height: 100%;
  padding: 0;
  border-radius: 2px;
  text-decoration: none;
}
.workshop-game .game-picture {
  width: 100%;
  aspect-ratio: 16/9;
  height: auto;
  min-height: 0;
  border-radius: 3px;
}
.game-copy {
  display: block;
  padding-top: 7px;
}
.workshop-game h2 {
  font:
    700 1rem/1.4 "Trebuchet MS",
    Arial,
    sans-serif;
  margin: 0 0 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.workshop-game p {
  font-size: 0.87rem;
  line-height: 1.5;
  margin: 0;
  color: var(--muted);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.game-link:hover h2,
.game-link:hover strong {
  text-decoration: none;
}
.game-link:hover {
  background: transparent;
  color: var(--accent);
}
.game-link:hover .game-picture {
  opacity: 0.92;
}
.more-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: max-content;
  min-height: 44px;
  margin: 6px auto 0;
  padding: 0 13px;
  font-size: 0.9rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.exercise-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 24px;
  margin: 0;
}
.exercise-card {
  min-width: 0;
}
.exercise-card > .game-link {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 7px 0;
  border-top: 1px solid var(--rule);
  border-radius: 0;
}
.exercise-card .game-picture {
  width: 110px;
  height: 108px;
  border-radius: 2px;
}
.exercise-card h3 {
  margin: 0 0 4px;
  font-size: 1rem;
  line-height: 1.35;
}
.exercise-card p {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0 0 4px;
}
.quiet-cta {
  font-size: 0.85rem;
  color: var(--accent);
}
.reading-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.reading-list > li {
  border-top: 1px solid var(--rule);
  margin: 0;
}
.reading-link {
  display: block;
  padding: 12px 0;
  text-decoration: none;
}
.reading-link h2 {
  font-size: 1rem;
  line-height: 1.4;
  margin: 0 0 4px;
  display: block;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}
.reading-link p {
  font-size: 0.9rem;
  line-height: 1.5;
  margin: 0;
  color: var(--muted);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.reading-link:hover h2 {
  color: var(--accent);
}
.category-layer {
  position: fixed;
  inset: 0 auto auto 0;
  width: 100vw;
  height: 100dvh;
  z-index: 30;
  background: #17251e70;
}
.category-panel {
  position: absolute;
  inset: 0 0 0 auto;
  width: 70vw;
  height: 100%;
  max-width: none;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  padding: 0 24px;
  box-shadow: -8px 0 30px #12221820;
  animation: drawer-in 180ms ease-out;
}
.category-panel > header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 60px;
  border-bottom: 1px solid var(--rule);
  flex: none;
}
.category-panel h2 {
  font-size: 1.1rem;
  margin: 0;
  line-height: 1.3;
}
.category-panel [data-close] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-width: 44px;
  min-height: 44px;
  border: 0;
  padding: 0 1px;
  border-radius: 0;
  font-size: 0.9rem;
}
.category-panel [data-close] > span {
  font-size: 24px;
  font-weight: 400;
}
.category-index {
  overflow: auto;
  min-height: 0;
  padding: 10px 0;
}
.category-index > a {
  display: flex;
  gap: 14px;
  align-items: center;
  min-height: 46px;
  padding: 4px 8px;
  text-decoration: none;
  font-size: 1rem;
  border-radius: 2px;
}
.category-index svg {
  flex: none;
  display: block;
}
.category-index [aria-current] {
  background: #e5ebe1;
  color: #5d341d;
  box-shadow: inset 2px 0 var(--accent);
}
.category-index > a:hover {
  background: #e9eee6;
}
.drawer-aux {
  display: flex;
  flex: none;
  gap: 8px 24px;
  flex-wrap: wrap;
  border-top: 1px solid var(--rule);
  padding-top: 8px;
  padding-bottom: max(12px, env(safe-area-inset-bottom));
}
.drawer-aux > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 0.9rem;
}
.category-layer[hidden] {
  display: none !important;
}
@keyframes drawer-in {
  from {
    transform: translateX(24px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}
.detail-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  margin: 0;
  min-width: 0;
}
.back-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  min-width: 44px;
  min-height: 44px;
  text-decoration: none;
  border: 0;
}
.back-link svg {
  display: block;
  flex: none;
}
.detail-heading h1 {
  font-size: 0.95rem;
  line-height: 1.4;
  margin: 0;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 500;
}
.detail-heading .title-open {
  border: 0;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  margin-left: auto;
}
.title-note {
  padding: 10px 12px;
  border: 1px solid var(--rule);
  margin: 0 0 10px;
}
.title-note p {
  margin: 0 0 6px;
}
.player-stage {
  padding: 0 !important;
  margin: 0 0 14px !important;
  border: 0 !important;
  background: transparent;
  color: var(--ink);
}
.player-media {
  aspect-ratio: 16/9;
  min-height: 0;
  max-height: 68dvh;
  background: #192226;
}
.player-media > [data-play] {
  align-self: end;
  justify-self: start;
  margin: 10px;
  background: #fff;
  color: #26332b;
  font-size: 0.9rem;
  border: 0;
  border-radius: 3px;
  min-height: 44px;
  max-width: calc(100% - 20px);
}
.player-media > .game-picture {
  border-radius: 3px;
}
.player-tools {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding-top: 4px;
}
.player-tools > button {
  min-height: 44px;
  padding: 0 8px;
  border: 0;
  font-size: 0.9rem;
}
.player-tools > button:disabled {
  opacity: 0.5;
}
.player-stage > [role="status"] {
  font-size: 0.85rem;
  line-height: 1.45;
  color: var(--muted);
  margin: 2px 0 0;
  max-width: 75ch;
}
.player-stage:fullscreen {
  background: #17221c;
  color: #fff;
}
.player-stage:fullscreen > [role="status"] {
  color: #fff;
}
.original-controls,
.source-section,
.info-section,
.prose {
  max-width: 72ch;
}
.original-controls h2,
.source-section h2,
.info-section h2,
.prose h2 {
  font-size: 1.1rem;
  margin: 16px 0 7px;
}
.original-controls p,
.source-section p {
  margin: 0 0 10px;
}
.inline-route {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.recommendations {
  margin-top: 20px;
  padding-top: 10px;
  border-top: 1px solid var(--rule);
}
.reading-preview {
  margin-top: 20px;
}
.article-heading h1 {
  font-weight: 700;
}
.article-body {
  max-width: 72ch;
  margin: 0;
}
.article-summary {
  font-size: 1.125rem;
  line-height: 1.6;
  margin: 0 0 20px;
}
.article-body section {
  margin: 0 0 24px;
}
.article-body h2 {
  font-size: 1.2rem;
  line-height: 1.35;
  margin: 14px 0 8px;
}
.article-body p {
  line-height: 1.7;
  margin: 8px 0 14px;
}
.source-note {
  color: var(--muted);
  font-size: 0.9rem;
}
.site-footer {
  margin-top: 20px;
  padding-block: 10px 18px;
  border-top: 1px solid var(--rule);
}
.site-footer > nav {
  display: flex;
  gap: 0 24px;
  flex-wrap: wrap;
}
.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  min-width: 44px;
  font-size: 0.88rem;
}
.lesson-step {
  max-width: 70ch;
  border-left: 2px solid var(--rule);
  padding: 4px 0 4px 14px;
  margin: 14px 0;
}
.lesson-step h2 {
  font-size: 1.05rem;
  margin: 8px 0;
}
.lesson-step label {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
}
.lesson-step input {
  width: 20px;
  height: 20px;
  flex: none;
}
.lesson-game > .game-link {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  text-decoration: none;
}
.lesson-game .game-picture {
  width: 140px;
  height: 100px;
}
.lesson-game h2 {
  font-size: 1rem;
}
[data-lesson] > a,
[data-invalid-lesson] > a,
[data-content-block="lesson-reset"] > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
[data-content-block="lesson-reset"] {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
[data-content-block="lesson-reset"] > p {
  flex-basis: 100%;
  margin-top: 0;
}
section[data-content-block] {
  padding-block: 8px;
  margin-bottom: 10px;
  border-bottom: 0;
}
[hidden] {
  display: none !important;
}
@media (min-width: 800px) {
  .workshop-game > .game-link {
    display: grid;
    grid-template-columns: 44% minmax(0, 1fr);
    gap: 14px;
    align-items: center;
  }
  .workshop-game .game-picture {
    aspect-ratio: auto;
    height: 128px;
  }
  .game-copy {
    padding: 0;
  }
  .workshop-grid {
    gap: 18px 30px;
  }
  .reading-link {
    padding-block: 12px;
  }
  .reading-link h2 {
    font-size: 1.03rem;
  }
  .category-index {
    max-width: 680px;
  }
  .category-panel {
    padding-inline: 32px;
  }
  .drawer-aux {
    margin-top: 8px;
  }
  .player-media {
    max-width: 820px;
  }
  .player-tools {
    max-width: 820px;
  }
  .workshop-masthead {
    max-width: 100%;
  }
}
@media (max-width: 799px) {
  .workshop-top,
  main,
  .site-footer,
  .announcement {
    padding-inline: 14px;
  }
  .brand {
    font-size: 1.05rem;
    gap: 7px;
  }
  .discovery-open {
    font-size: 0.85rem;
    gap: 6px;
  }
  header[id="top"] > nav {
    gap: 19px;
  }
  .workshop-grid {
    gap: 16px 14px;
  }
  .exercise-list {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .exercise-card .game-picture {
    height: 88px;
  }
  .exercise-card > .game-link {
    padding-block: 6px;
  }
  .category-panel {
    padding-inline: 16px;
  }
  .reading-link {
    padding-block: 10px;
  }
  .reading-link h2 {
    font-size: 0.95rem;
    line-height: 1.4;
  }
  .reading-link p {
    font-size: 0.85rem;
    line-height: 1.45;
  }
  .drawer-aux {
    gap: 0 16px;
  }
  .category-panel > header {
    min-height: 58px;
  }
  .category-index > a {
    min-height: 46px;
  }
  .detail-heading h1 {
    font-size: 0.88rem;
  }
  .lesson-game > .game-link {
    grid-template-columns: 100px minmax(0, 1fr);
  }
  .lesson-game .game-picture {
    width: 100px;
    height: 90px;
  }
}
@media (max-width: 360px) {
  .workshop-top,
  main,
  .site-footer,
  .announcement {
    padding-inline: 12px;
  }
  .brand {
    font-size: 1rem;
  }
  .discovery-open > span {
    display: none;
  }
  .discovery-open {
    min-width: 44px;
    justify-content: center;
  }
  .workshop-grid {
    gap: 16px 12px;
  }
  header[id="top"] > nav {
    gap: 18px;
  }
  .category-panel {
    padding-inline: 12px;
  }
  .category-panel > header {
    flex-wrap: wrap;
    gap: 0 8px;
  }
  .category-panel h2 {
    font-size: 1rem;
  }
}
@media (orientation: landscape) and (max-height: 500px) {
  .category-panel > header {
    min-height: 48px;
  }
  .category-index {
    flex: 1;
  }
  .drawer-aux {
    padding-block: 0;
  }
  .workshop-game > .game-link {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 12px;
  }
  .workshop-game .game-picture {
    height: 92px;
    aspect-ratio: auto;
  }
  .game-copy {
    padding: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .category-panel {
    animation: none;
  }
  * {
    scroll-behavior: auto !important;
  }
}

.category-layer[data-closing] {
  pointer-events: none;
  background: transparent;
}

.article-game .workshop-grid {
  grid-template-columns: minmax(0, 1fr);
  max-width: 72ch;
}
.article-game .game-link {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
}
.article-game .game-picture {
  height: 100%;
  min-height: 110px;
  aspect-ratio: auto;
}
.article-game .game-copy {
  align-self: center;
  padding: 0;
}

.article-body > .article-summary {
  margin: 0 0 12px;
}

.lesson-game h2,
.exercise-card p {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}
/* The reading index starts close to its label; every row remains one large link. */
.reading-link {
  padding-block: 5px;
}
body[data-page="articles"] .page-label {
  margin-bottom: 2px;
}
.status-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 44px;
}
.status-heading h1 {
  margin: 0;
}
.status-heading > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.recommendations--status {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.recommendations--status > .section-heading {
  display: none;
}
.prose:first-of-type > h2 {
  margin-top: 0;
  margin-bottom: 4px;
}
.prose:first-of-type > p:first-of-type {
  margin-top: 4px;
}
.article-body > .article-summary {
  margin-bottom: 8px;
}
.article-body > section:first-of-type h2 {
  margin-top: 8px;
  margin-bottom: 6px;
}
.article-body > section:first-of-type p:first-of-type {
  margin-top: 6px;
}

/* Short pages use compact panoramic previews in their finite game bench. */
@media (max-width: 799px) {
  .recommendations .game-picture {
    aspect-ratio: 12/5;
  }
}

.recommendations--reading .workshop-grid {
  grid-template-columns: minmax(0, 1fr);
  max-width: 760px;
  gap: 14px;
}
.recommendations--reading .workshop-game > .game-link {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
}
.recommendations--reading .game-picture {
  height: 180px;
  aspect-ratio: 1;
}
.recommendations--reading .game-copy {
  padding: 0;
}
@media (max-width: 799px) {
  .recommendations--reading .workshop-game > .game-link {
    grid-template-columns: 45% minmax(0, 1fr);
    gap: 14px;
  }
  .recommendations--reading .game-picture {
    height: auto;
    aspect-ratio: 1;
  }
}

/* A real final item owns the full remaining row, with a normal-size thumbnail. */
body:is([data-page="home"], [data-page="games"], [data-page="category"])
  .workshop-grid
  > li:last-child:nth-child(odd) {
  grid-column: 1 / -1;
}
body:is([data-page="home"], [data-page="games"], [data-page="category"])
  .workshop-grid
  > li:last-child:nth-child(odd)
  > .game-link {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}
@media (max-width: 799px) {
  body:is([data-page="home"], [data-page="games"], [data-page="category"])
    .workshop-grid
    > li:last-child:nth-child(odd)
    > .game-link {
    grid-template-columns: 45% minmax(0, 1fr);
  }
}

/* Reading previews keep space after each rule without delaying the first title. */
[data-module="reading"] .reading-link,
.reading-preview .reading-link {
  padding-block: 10px;
}
[data-module="reading"] .reading-list > li:first-child .reading-link,
.reading-preview .reading-list > li:first-child .reading-link {
  padding-top: 3px;
}
[data-module="reading"] .reading-link h2,
.reading-preview .reading-link h2 {
  line-height: 1.5;
  margin-bottom: 5px;
}
[data-module="reading"] .reading-link p,
.reading-preview .reading-link p {
  line-height: 1.6;
}

/* Release the reserved action column when enlarged text needs separate rows. */
[data-module] { container-type:inline-size; }
@container (max-width:17em) {
 .section-heading { padding-right:0; flex-wrap:wrap; }
 .section-heading > a { position:static; }
}
