/* Shared Playroom components for the entire site; no legacy utility framework. */
.pr-dock-button { gap: 4px; padding: 8px 3px; align-content: center; }
.pr-dock-button > span { font-size: 11px; line-height: 1.2; font-weight: 850; text-align: center; }
.pr-page { max-width: 1200px; margin: 0 auto; }
.pr-page-head { display: grid; justify-items: start; gap: 12px; margin-bottom: 26px; }
.pr-eyebrow { color: var(--muted); font-size: 11px; font-weight: 900; letter-spacing: 1.5px; text-transform: uppercase; }
.pr-surface { min-width: 0; padding: 24px; margin-bottom: 24px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.pr-surface > h2 { margin-bottom: 8px; }
.pr-reference-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,240px),1fr)); gap: 22px; padding-bottom: 8px; }
.pr-reference-card { display: grid; justify-items: start; gap: 12px; padding: 24px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); text-decoration: none; }
.pr-reference-card:hover { border-color: var(--sky-700); background: var(--sky-50); }
.pr-reference-icon { display: grid; place-items: center; padding: 12px; border-radius: 14px; background: var(--sky-50); color: var(--sky-700); }
.pr-reference-card:nth-child(3n+2) .pr-reference-icon { background: var(--orange-50); color: var(--action); }
.pr-back { display: inline-flex; align-items: center; min-height: 44px; margin-bottom: 16px; font-weight: 850; text-underline-offset: 4px; }
.pr-lesson { max-width: 960px; margin-inline: auto; padding: 28px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); line-height: 1.65; }
.pr-lesson .pr-lesson-title { margin-bottom: 24px; overflow-wrap: anywhere; }
.pr-lesson .pr-lesson-heading { margin-bottom: 10px; color: var(--sky-700); }
.pr-lesson-section { min-width: 0; margin-bottom: 26px; }
.pr-lesson-intro { max-width: 80ch; }
.pr-lesson-list { padding-left: 24px; }
.pr-code { max-width: 100%; overflow: auto; margin: 0; padding: 18px; background: var(--sky-50); border: 1px solid #c4dfe4; border-radius: 14px; font: 14px/1.65 ui-monospace,monospace; color: var(--ink); white-space: pre; }
#graph { width: 100%; height: 440px; overflow: hidden; }
#graph svg { display: block; max-width: 100%; }
#graph .link { stroke: var(--brand-sky); stroke-width: 2px; }
#graph .nodes > g { cursor: pointer; }
/* SVG nodes use the circular keyboard cue, never the browser's click rectangle. */
.pr-home #graph .nodes > g { outline: none; }
#graph .nodes > g:focus-visible circle { stroke: var(--action); stroke-width: 5px; }
.pr-map-list { margin-top: 14px; }
.pr-map-list summary { min-height: 44px; cursor: pointer; font-weight: 850; }
.pr-resource-links { display: flex; flex-wrap: wrap; gap: 12px; padding: 12px 0; }
.pr-search-form { display: grid; grid-template-columns: minmax(0,1fr); gap: 8px; margin-top: 18px; }
.pr-search-form label { font-size: 14px; font-weight: 850; }
.pr-search-row { display: flex; min-width: 0; gap: 12px; align-items: stretch; }
.pr-search-row input { flex: 1; min-width: 0; min-height: 44px; padding: 10px 12px; color: var(--ink); border: 2px solid #ccd7d5; border-radius: 12px; background: var(--paper); }
.pr-feedback { min-height: 24px; margin-top: 14px !important; color: var(--muted); font-size: 14px; }
.pr-image-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,180px),1fr)); gap: 16px; }
.pr-image-result { min-width: 0; display: grid; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 18px; background: var(--paper); }
.pr-image-result img { width: 100%; height: 150px; object-fit: contain; }
@media (max-width:700px) {
  .pr-dock-button > span { font-size: 10px; }
  .pr-surface, .pr-lesson, .pr-reference-card { padding: 18px; }
  .pr-search-row { flex-direction: column; }
  #graph { height: 330px; }
  .pr-code { padding: 12px; font-size: 13px; }
}
@media (max-width:430px) {
  .pr-app { grid-template-columns: minmax(0,1fr); grid-template-rows: 57px minmax(0,1fr) 76px; }
  .pr-top { grid-row: 1; }
  .pr-stage { grid-column: 1; grid-row: 2; padding: 16px 14px 24px; }
  .pr-dock { grid-column: 1; grid-row: 3; flex-direction: row; justify-content: space-around; gap: 0; padding: 8px 0; border-right: 0; border-top: 1px solid var(--line); overflow-x: auto; overflow-y: hidden; }
  .pr-dock .pr-dock-button { flex: 1 1 0; min-width: 44px; width: auto; max-width: 64px; min-height: 58px; border-radius: 12px; padding: 6px 2px; }
  .pr-dock-button > span { font-size: 9px; overflow-wrap: anywhere; }
  .pr-dock-button[aria-current='page']::before { left: 50%; top: -8px; width: 24px; height: 4px; transform: translateX(-50%); border-radius: 0 0 4px 4px; }
  .pr-help-dock { display: contents; }
  .pr-dock .pr-help-cancel { flex: 1 1 0; max-width: 64px; min-width: 44px; min-height: 58px; padding: 6px 2px; font-size: 10px !important; }
}

/* Home and login are open public pages, not workshop workspaces. */
.pr-shell--public .pr-app { grid-template-columns: minmax(0,1fr); grid-template-rows: auto minmax(0,1fr); }
.pr-shell--public .pr-top { grid-row: 1; min-height: 68px; background: var(--brand-orange); color: var(--surface); border-bottom: 0; padding-block: 10px; }
.pr-shell--public .pr-stage { grid-column: 1; grid-row: 2; }
.pr-shell--public .pr-brand { flex-shrink: 0; }
.pr-shell--public .pr-brand #logoLink { font-size: 20px; }
.pr-shell--public .pr-original-logo { background: var(--surface); border-radius: 12px; padding: 3px; }
.pr-public-nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; margin-left: auto; }
.pr-public-nav .pr-dock-button { display: inline-flex; gap: 7px; width: auto; min-height: 44px; padding: 9px 12px; border: 0; border-radius: 10px; background: var(--action); color: var(--surface); box-shadow: none; }
.pr-public-nav .pr-dock-button > span { font-size: 14px; white-space: nowrap; text-wrap: nowrap; overflow-wrap: normal; }
.pr-public-nav .pr-dock-button .pr-icon { width: 20px; height: 20px; }
.pr-public-nav .pr-dock-button:is(:hover,[aria-current='page']) { background: var(--ink); }
.pr-public-nav .pr-dock-button[aria-current='page']::before { content: none; }
.pr-shell--public .pr-account-tools { margin-left: 8px; }
.pr-shell--public .pr-account-tools > .pr-text-link { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 12px; border-radius: 10px; color: var(--ink); background: var(--surface); white-space: nowrap; text-wrap: nowrap; }
.pr-shell--public .pr-account-menu, .pr-shell--public .pr-avatar { color: var(--ink); }
.pr-shell--public .pr-top :focus-visible { outline-color: var(--surface); }
.pr-shell--public .pr-account-menu :focus-visible { outline-color: var(--sky-700); }
.pr-shell--public .pr-form-card { margin-inline: auto; }
.pr-shell--public .hca-workshop { max-width: none; }
.pr-home { max-width: 1440px; }
.pr-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.pr-home-map { margin-bottom: 28px; text-align: center; }
.pr-home #graph { height: clamp(360px, calc(100dvh - 146px), 780px); }
.pr-home .pr-map-list { text-align: left; }
@media (max-width:1000px) {
  .pr-shell--public .pr-top { flex-wrap: wrap; padding: 10px 14px; gap: 8px; }
  .pr-shell--public .pr-brand #logoLink { font-size: 19px; }
  .pr-shell--public .pr-original-logo { width: 38px; height: 38px; }
  .pr-shell--public .pr-account-tools { margin-left: auto; }
  .pr-public-nav { order: 3; flex-basis: 100%; margin: 0; }
  .pr-public-nav .pr-dock-button .pr-icon { display: none; }
}
