/* learn.excavaacademy.com — built from the Learner Screen Shells canvas (29 Oct 2026): sage frame, twill or paper
   board, Atkinson Hyperlegible Next, crest and wordmark bottom right with the vision line. Made for the Chromebook
   (1366 × 768) and still usable on a phone. */
:root {
	--sage: #2F5D4E; --sage-light: #A9BFA8; --paper: #FAF7F0; --card: #FFFDF8; --white: #FFFFFF;
	--ink: #24211D; --ink-soft: #5E584F; --outline: #CFC8BC; --orange: #BF5700; --navy: #0B1D3A; --ochre: #9D6822;
	--track: #E3D9C4; --error-bg: #FBE9E2; --error: #8A2D10;
	color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--sage); color: var(--ink); }
body { font: 400 16px/1.4 'Atkinson Hyperlegible Next', 'Atkinson Hyperlegible', Arial, sans-serif; }
a { color: var(--sage); }
p { margin: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--ink-soft); }
.small { font-size: 14px; }
.strong { font-weight: 700; }
.grow { flex-grow: 1; min-width: 0; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.row.baseline { align-items: baseline; }
.row.end { justify-content: flex-end; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.inline { display: inline; margin: 0; }

/* the frame: a sage band on top, the board filling the rest */
.frame { min-height: 100vh; display: flex; flex-direction: column; }
.band { min-height: 64px; padding: 10px 24px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.band-left, .band-right { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.band-title { font-weight: 700; color: var(--paper); }
.clock { font-size: 18px; font-weight: 700; color: var(--paper); font-variant-numeric: tabular-nums; }
.crumbs { display: flex; gap: 10px; font-weight: 700; }
.crumbs a { color: var(--sage-light); text-decoration: none; }
.crumbs a:hover { color: var(--paper); text-decoration: underline; }
.crumbs span { color: var(--paper); }
.crumbs span[aria-hidden] { color: var(--sage-light); }
.board { flex-grow: 1; margin: 0 16px 16px; border-radius: 16px; padding: 32px; }
.board.paper { background: var(--paper); }
.board.twill { background: #F3EBD8 url(/learn/twill.webp) center / 100% 100% no-repeat; padding: 44px 60px 48px; }
.board.center { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 30px; margin-top: 16px; }

/* buttons: 44 px or taller everywhere */
.btn { min-height: 44px; padding: 0 18px; border-radius: 8px; border: none; font: inherit; font-size: 16px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; cursor: pointer; }
.btn-orange { background: var(--orange); color: var(--white); }
.btn-orange:hover { background: #A84C00; }
.btn-light { background: var(--paper); color: var(--sage); }
.btn-outline { background: transparent; color: var(--paper); box-shadow: inset 0 0 0 2px var(--paper); }
.btn-outline:hover { background: rgba(250, 247, 240, 0.12); }
.btn-big { min-height: 54px; padding: 0 30px; font-size: 18px; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }

.card { background: var(--card); border: 1px solid var(--outline); border-radius: 12px; padding: 18px 22px; }
.label { margin: 0 0 4px; font-size: 14px; font-weight: 700; color: var(--ink-soft); }
.bar { height: 10px; border-radius: 5px; background: var(--track); overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--sage); border-radius: 5px; }

/* the crest, wordmark and vision line */
.lockup { display: inline-flex; flex-direction: column; align-items: stretch; gap: 6px; }
.lockup-row { display: flex; align-items: center; gap: 12px; }
.lockup .crest { height: 72px; width: auto; }
.lockup .wordmark { width: 228px; height: auto; }
.vision { font: 600 10px/1.2 Cinzel, 'Times New Roman', serif; letter-spacing: 0.3px; text-align: center; white-space: nowrap; color: var(--ink); }
.tilde { color: var(--ochre); padding: 0 0.35em; }
.lockup.big .lockup-row { gap: 26px; }
.lockup.big .crest { height: 168px; }
.lockup.big .wordmark { width: 530px; max-width: 60vw; }
.lockup.big .vision { font-size: 22px; letter-spacing: 0.6px; }

/* sign in */
.signin { width: 400px; max-width: 100%; display: flex; flex-direction: column; gap: 8px; padding: 24px 28px; }
.signin label { font-size: 15px; font-weight: 700; margin-top: 6px; }
.signin input { height: 46px; border: 1px solid #8C857A; border-radius: 8px; padding: 0 14px; font: inherit; font-size: 17px; background: var(--white); color: var(--ink); }
.signin .btn { margin-top: 12px; }
.help { margin-top: 8px; font-size: 14px; color: var(--ink-soft); text-align: center; }
.error { padding: 10px 12px; border-radius: 8px; background: var(--error-bg); color: var(--error); font-weight: 600; }

/* home */
.home { display: grid; grid-template-columns: 280px minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
.col { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.col.side { align-self: stretch; justify-content: space-between; }
.profile { display: flex; align-items: center; gap: 14px; }
.avatar { width: 64px; height: 64px; border-radius: 32px; background: #ECE7DE; border: 1px solid var(--outline); display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 700; color: var(--ink-soft); }
.name { font-size: 20px; font-weight: 700; }
.badges-sm { display: flex; flex-wrap: wrap; gap: 8px; }
.badge-sm { width: 56px; height: 56px; }
.next { display: flex; align-items: center; gap: 20px; border: 2px solid var(--sage); background: var(--white); }
.next-title { font-size: 26px; font-weight: 700; }
.next-title.sm { font-size: 20px; }
.subject-link { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0; text-decoration: none; color: var(--ink); }
.subject-link:hover .subject-name { text-decoration: underline; }
.subject-name { font-size: 20px; font-weight: 700; color: var(--sage); }
.subject-unit { display: flex; flex-direction: column; gap: 6px; padding: 0 0 12px; }

/* Ask Excava! */
.ask { position: relative; }
.ask summary { list-style: none; }
.ask summary::-webkit-details-marker { display: none; }
.ask-panel { position: absolute; right: 0; top: calc(100% + 8px); width: 340px; max-width: 90vw; z-index: 20; background: var(--card); border: 1px solid var(--outline); border-radius: 12px; padding: 16px; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18); }
.ask-title { margin: 0 0 8px; font-size: 16px; color: var(--sage); }
.ask-log { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-direction: column; gap: 8px; max-height: 260px; overflow-y: auto; }
.ask-item { background: #E6ECE5; border-radius: 10px; padding: 8px 12px; }
.ask-msg { white-space: pre-wrap; }
.ask-meta { margin-top: 4px; font-size: 13px; color: var(--ink-soft); }
.ask-answer { margin-top: 6px; padding: 8px 10px; background: var(--white); border: 1px solid var(--outline); border-radius: 8px; }
.ask-empty { color: var(--ink-soft); font-size: 15px; }
.ask-form { display: flex; flex-direction: column; gap: 8px; }
.ask-form textarea { min-height: 72px; resize: vertical; border: 1px solid #8C857A; border-radius: 8px; padding: 10px 12px; font: inherit; color: var(--ink); background: var(--white); }
.ask-form .btn { align-self: flex-end; }
.ask-home { display: flex; flex-direction: column; }

/* the subject page */
.subject.board, .board.subject { display: flex; gap: 28px; }
.patch-col { width: 250px; flex-shrink: 0; display: flex; flex-direction: column; align-items: stretch; gap: 10px; }
.patch { width: 250px; height: auto; align-self: center; }
.unit-title { margin: 0; font: 650 34px/40px Fraunces, Georgia, serif; color: var(--navy); }
.week-title { margin: 0; font-size: 18px; }
.badge-grid { display: flex; flex-wrap: wrap; gap: 22px; margin: 14px 0; }
.badge-row { display: flex; gap: 10px; }
.badge-cell { margin: 0; width: 82px; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.badge-cell a, .badge-cell span[role] { display: block; width: 76px; height: 76px; border-radius: 50%; }
.badge { width: 76px; height: 76px; display: block; }
.badge-cell figcaption { font-size: 12px; line-height: 15px; text-align: center; }
.badge-cell.upnext a { box-shadow: 0 0 0 3px var(--orange); background: var(--white); }
.badge-cell.upnext .badge { opacity: 0.55; }
.badge-cell.upnext figcaption { color: var(--orange); font-weight: 700; }
.badge-cell.ready .badge { opacity: 0.55; }
.badge-cell.locked .badge { filter: grayscale(1); opacity: 0.32; }
.badge-cell.locked figcaption { color: var(--ink-soft); }
.next-bar { display: flex; align-items: center; gap: 16px; border-top: 1px solid var(--track); padding-top: 12px; }
.week-closed { background: var(--card); border: 1px solid var(--outline); border-radius: 10px; padding: 11px 20px; display: flex; justify-content: space-between; }

/* narrow screens: one column */
@media (max-width: 1000px) {
	.home { grid-template-columns: 1fr; }
	.board.subject { flex-direction: column; }
	.board.twill { padding: 24px 20px; background-size: cover; }
	.patch-col { width: 100%; }
	.next { flex-wrap: wrap; }
}
@media (max-width: 560px) {
	.board, .board.paper { padding: 16px; margin: 0 8px 8px; }
	.vision { white-space: normal; }
	.lockup .wordmark { width: 180px; }
}

/* Founder, 29 Oct 2026, on the badge page: crest and wordmark up about 1/8 inch, the unit patch down about 1/8 inch */
.board.subject .lockup { position: relative; top: -12px; }
.board.subject .patch-col { padding-top: 18px; }
.board.subject .patch { position: relative; left: 9px; }
/* Founder, 29 Oct 2026: the unit title 3/16 inch lower. The crest and wordmark are pinned to the board's bottom-right
   corner (where he placed them) so the lower title cannot push them down or off the screen. */
.board.subject { position: relative; }
.board.subject .row.end { position: absolute; right: 60px; bottom: 68px; }
.board.subject .row.end .lockup { top: 0; }
.board.subject .unit-title { margin-top: 18px; }

/* the badge just earned (arriving from Finish): a gold ring that glows in once, and a line in the week row */
.badge-cell.fresh a { box-shadow: 0 0 0 3px #C9A227, 0 0 16px 6px rgba(201, 162, 39, 0.5); animation: earned 2.4s ease-out 1; }
.badge-cell.fresh figcaption { color: #7A5410; font-weight: 700; }
.earned-now { color: #7A5410; }
@keyframes earned { 0% { transform: scale(0.6); box-shadow: 0 0 0 0 rgba(201, 162, 39, 0); } 45% { transform: scale(1.12); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .badge-cell.fresh a { animation: none; } }

/* staff inbox */
.inbox { display: flex; flex-direction: column; gap: 16px; }
.tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.tab { min-height: 44px; padding: 0 16px; border-radius: 8px; display: inline-flex; align-items: center; font-weight: 700; text-decoration: none; color: var(--sage); border: 2px solid var(--sage); }
.tab.on { background: var(--sage); color: var(--paper); }
.inbox-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; max-width: 900px; }
.inbox-item { display: flex; flex-direction: column; gap: 10px; }
