/* Local learning activities share the workshop's dark palette. */
.foundation { display: grid; gap: 18px; min-width: 0; margin: 24px 0 8px; }
.foundation > h3 { margin-bottom: 0; }
.foundation h4 { font-size: 1rem; line-height: 1.45; margin: 0; }
.foundation p + p { margin-top: 10px; }
.foundation-notice { color: var(--muted); font-size: .8rem; border-left: 3px solid var(--line); padding: 6px 12px; }
.foundation-instruction { line-height: 1.65; }
.foundation-paths { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.foundation-path { border: 1px solid #527883; background: #102f3d; padding: 16px; border-radius: 12px; min-width: 0; }
.foundation-path > strong { color: #a4f1ef; }
.foundation-path ol { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 24px; }
.foundation-path li { font-size: .88rem; position: relative; }
.foundation-path li + li::before { content: '↓'; color: #ffcc87; position: absolute; left: 0; top: -24px; }
.foundation-cards { display: grid; gap: 14px; }
.foundation-card { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: #0a1d2b; }
.foundation-card > p { font-size: .93rem; line-height: 1.65; }
.foundation-number { display: inline-flex; width: 26px; height: 26px; align-items: center; justify-content: center; margin-right: 9px; border-radius: 50%; background: #173c44; color: #a4f1ef; font-weight: 750; font-size: .8rem; }
.foundation-choices { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.foundation button { min-height: 44px; max-width: 100%; overflow-wrap: anywhere; text-align: left; line-height: 1.4; font-size: .86rem; }
.foundation-choices button { flex: 1 1 155px; justify-content: flex-start; padding: 11px 13px; background: #102b3e; border-color: #4b6c80; font-weight: 550; }
.foundation button[aria-pressed=true] { background: #19454a; border-color: #a4f1ef; color: #e2fffa; box-shadow: inset 0 0 0 1px #a4f1ef; }
.foundation button[aria-pressed=true]::before { content: '●'; font-weight: 800; }
.foundation button:hover { background: #1c3e50; }
.foundation button[aria-pressed=true]:hover { background: #20555b; }
.foundation-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.foundation-actions button:first-child { color: #08252b; background: #a4f1ef; border-color: #a4f1ef; }
.foundation-actions button:first-child:hover { background: #d0fffc; }
.foundation-feedback { padding: 18px; border: 1px solid #6cb3aa; border-left-width: 4px; background: #11312f; border-radius: 0 12px 12px 0; color: #d5f6ec; line-height: 1.65; font-size: .9rem; }
.foundation-feedback p { margin-top: 12px; }
.foundation-feedback > p:first-child { margin-top: 0; }
.foundation-results { list-style: none; margin: 0; padding: 0; display: grid; gap: 15px; }
.foundation-case { display: grid; gap: 12px; }
.foundation-case p + p { margin-top: 0; }
.foundation-case .foundation-choices { margin-top: 0; }
.foundation-permissions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.foundation-permissions h4 { grid-column: 1 / -1; margin-bottom: 3px; }
.foundation-permissions button { justify-content: flex-start; background: #102b3e; border-color: #4b6c80; font-weight: 550; }
.foundation-trace:has(ol) { border-left: 2px solid #5b929c; padding-left: 18px; }
.foundation-trace ol { padding: 0; margin: 0; list-style: none; display: grid; gap: 12px; }
.foundation-trace li { padding: 15px; border: 1px solid #42697c; border-radius: 10px; background: #102a3b; font-size: .9rem; line-height: 1.65; }
.foundation-trace li strong { color: #b7eeed; }
.foundation-trace li p { margin-top: 7px; }
.foundation-trace li.foundation-blocked { background: #362817; border-color: #ad8953; color: #ffe0ad; }
.foundation-trace li.foundation-blocked strong { color: #ffe0ad; }
.foundation-closing { border-top: 1px solid var(--line); padding-top: 15px; }
@media (max-width: 620px) {
  .foundation-paths, .foundation-permissions { grid-template-columns: minmax(0, 1fr); }
  .foundation-card { padding: 15px; }
  .foundation-choices button { flex-basis: 100%; }
  .foundation-actions button { flex: 1 1 170px; justify-content: center; }
  .foundation-trace:has(ol) { padding-left: 10px; }
}
@media print {
  .foundation-paths { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foundation-card, .foundation-path, .foundation-feedback, .foundation-trace li { break-inside: avoid; border-color: #888; }
  .foundation-choices button[aria-pressed=true], .foundation-permissions button[aria-pressed=true] { display: block !important; border-color: #888; box-shadow: none; }
  .foundation-notice, .foundation-actions { display: none !important; }
}
