@font-face
{
    font-family: Fraunces;
    src: url("./fonts/fraunces.woff2") format("woff2");
    font-weight: 100 900;
    font-display: swap;
}

@font-face
{
    font-family: Atkinson;
    src: url("./fonts/atkinson.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
}

@font-face
{
    font-family: Atkinson;
    src: url("./fonts/atkinson-bold.woff2") format("woff2");
    font-weight: 700;
    font-display: swap;
}

@font-face
{
    font-family: "JetBrains Mono";
    src: url("./fonts/jetbrains.woff2") format("woff2");
    font-weight: 100 800;
    font-display: swap;
}

:root
{
    --paper: #F6F0E2;
    --panel: #FFFBF1;
    --line: #DDD2BA;
    --ink: #25302A;
    --muted: #5E695D;
    --board: #1F4A3C;
    --board-deep: #173A2F;
    --console: #122B23;
    --chalk: #F3F0E3;
    --chalk-dim: #B9C9B8;
    --marker: #F5CF3A;
    --mint: #8FD3A8;
    --clay: #E58E73;
    --sky: #9CCBE0;
    --ledge: #C8B48F;
    font-family: Atkinson, sans-serif;
    color: var(--ink);
    background: var(--paper);
    font-synthesis: none;
}

*
{
    box-sizing: border-box;
}

body
{
    margin: 0;
    overflow: hidden;
}

button, input, textarea
{
    font: inherit;
}

button, a
{
    -webkit-tap-highlight-color: transparent;
}

button
{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 36px;
    padding: 8px 12px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: inherit;
    cursor: pointer;
    line-height: 1.25;
}

button:hover:not(:disabled)
{
    background: #25302A0C;
}

button:disabled
{
    cursor: default;
    opacity: .35;
}

button:focus-visible, a:focus-visible, [tabindex]:focus-visible, input:focus-visible
{
    outline: 2px solid var(--ink);
    outline-offset: 3px;
}

.slide-surface button:focus-visible, .slide-surface a:focus-visible, .slide-surface input:focus-visible
{
    outline-color: var(--marker);
}

svg
{
    flex-shrink: 0;
}

a
{
    color: inherit;
}

p
{
    line-height: 1.45;
}

#app
{
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    height: 100dvh;
}

#app.collapsed
{
    grid-template-columns: 60px minmax(0, 1fr);
}

.sidebar
{
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: var(--panel);
    border-right: 1px solid var(--line);
    z-index: 20;
}

.sidebar-header
{
    padding: 28px 23px 18px;
}

.brand
{
    display: flex;
    gap: 12px;
    align-items: center;
    font-size: 15px;
    line-height: 1.15;
}

.brand strong
{
    max-width: 150px;
}

.brand-mark
{
    width: 34px;
    height: 36px;
    flex-shrink: 0;
    background: var(--board);
    border-radius: 4px;
    color: var(--chalk);
    font: 500 26px Fraunces, serif;
    text-align: center;
    position: relative;
}

.brand-mark::after
{
    content: "";
    position: absolute;
    bottom: 5px;
    left: 8px;
    right: 8px;
    height: 2px;
    background: var(--marker);
}

.course
{
    font-size: 12px;
    color: var(--muted);
    max-width: 195px;
    margin: 21px 0 9px;
}

.sidebar h2
{
    font: 500 25px / 1.1 Fraunces, serif;
    letter-spacing: -.5px;
    margin: 0 0 21px;
}

.score-row
{
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
}

.score-pill
{
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 30px;
    padding: 3px 11px;
    font: 500 12px / 1.3 "JetBrains Mono", monospace;
    white-space: nowrap;
}

.score-segments
{
    display: flex;
    gap: 5px;
    margin-top: 10px;
}

.score-segments span
{
    height: 4px;
    background: var(--line);
    border-radius: 2px;
    flex: 1;
}

.score-segments .correct
{
    background: var(--mint);
}

.score-segments .incorrect
{
    background: var(--clay);
}

.outline
{
    flex: 1;
    overflow-y: auto;
    scrollbar-width: thin;
    min-height: 0;
    padding-bottom: 12px;
}

.outline section
{
    margin-bottom: 9px;
}

.outline h3
{
    font: 400 10px "JetBrains Mono", monospace;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--muted);
    margin: 12px 23px 8px;
}

.outline-row
{
    display: flex;
    align-items: center;
    height: 40px;
    text-decoration: none;
    padding: 0 14px 0 20px;
    gap: 9px;
    border-left: 3px solid transparent;
    font-size: 13px;
}

.outline-row:hover, .outline-row.current
{
    background: var(--paper);
}

.outline-row.current
{
    border-left-color: var(--marker);
    font-weight: 700;
}

.slide-index
{
    font: 400 11px "JetBrains Mono", monospace;
    color: var(--muted);
}

.type-icon
{
    color: var(--muted);
    height: 17px;
}

.type-icon svg, .row-status svg
{
    width: 16px;
    height: 16px;
}

.outline-title
{
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    flex: 1;
}

.row-status
{
    width: 16px;
    height: 16px;
    color: var(--muted);
}

.row-status.correct
{
    color: #38764C;
}

.row-status.incorrect
{
    color: #A5482C;
}

.sidebar-footer
{
    border-top: 1px solid var(--line);
    padding: 18px 22px 10px;
}

.instructor-small
{
    display: flex;
    align-items: center;
    gap: 11px;
}

.instructor-small img, .office img
{
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}

.instructor-small strong
{
    display: block;
    font-size: 13px;
}

.text-button
{
    padding: 2px 0;
    min-height: 24px;
    color: var(--muted);
    font-size: 11px;
}

.footer-bottom
{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    margin-top: 10px;
}

.footer-bottom a
{
    font-size: 10px;
    text-decoration: none;
    color: var(--muted);
}

.icon-button
{
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    padding: 8px;
}

.rail-expand
{
    display: none;
}

.collapsed .sidebar-header, .collapsed .sidebar-footer, .collapsed .outline h3,
.collapsed .outline-title, .collapsed .type-icon
{
    display: none;
}

.collapsed .outline
{
    padding-top: 64px;
}

.collapsed .outline-row
{
    padding-left: 16px;
    gap: 2px;
}

.collapsed .row-status
{
    width: 8px;
    margin-left: -4px;
}

.collapsed .row-status svg
{
    width: 10px;
}

.collapsed .rail-expand
{
    display: block;
    position: absolute;
    top: 16px;
    left: 12px;
}

.main
{
    display: grid;
    grid-template-rows: minmax(0, 1fr) 56px;
    min-width: 0;
    min-height: 0;
}

.stage-area
{
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    padding: 24px;
    background-image: radial-gradient(#8D79500A .7px, transparent .7px);
    background-size: 6px 6px;
}

.stage-eyebrow
{
    position: absolute;
    top: 27px;
    left: 26px;
    right: 26px;
    display: flex;
    justify-content: space-between;
    font: 400 10px "JetBrains Mono", monospace;
    letter-spacing: 1.2px;
    color: var(--muted);
}

.stage-note
{
    position: absolute;
    bottom: 27px;
    font: 500 15px Fraunces, serif;
    color: var(--muted);
    font-style: italic;
}

.canvas-size
{
    position: relative;
    flex: none;
    box-shadow: 0 18px 40px #25302A2E;
    border-radius: 14px 14px 0 0;
}

.slide-surface
{
    width: 1280px;
    height: 720px;
    position: relative;
    overflow: hidden;
    color: var(--chalk);
    background: radial-gradient(ellipse at 10% 30%, #F3F0E30A, transparent 70%),
        radial-gradient(ellipse at 80% 80%, #F3F0E30A, transparent 60%), var(--board);
    border-radius: 14px 14px 0 0;
    animation: slide-in 180ms ease-out;
}

.slide-surface::before
{
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: .045;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
}

.slide-content
{
    padding: 64px;
    position: relative;
    height: 100%;
}

.ledge
{
    height: 6px;
    width: 100%;
    background: var(--ledge);
    position: absolute;
    top: 100%;
}

.slide-surface h1, .slide-surface h2
{
    font: 500 56px / 1.02 Fraunces, serif;
    letter-spacing: -.01em;
    margin: 0 0 28px;
}

.slide-surface p
{
    font-size: 24px;
    margin: 0 0 24px;
}

.slide-surface .kicker
{
    font: 400 18px / 1.5 "JetBrains Mono", monospace;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--chalk-dim);
    margin: 0 0 25px;
}

.slide-surface button
{
    font-size: 21px;
    padding: 13px 20px;
    min-height: 50px;
}

.slide-surface .primary, .primary
{
    color: var(--ink);
    background: var(--marker);
    font-weight: 700;
}

.slide-surface .primary:hover:not(:disabled), .primary:hover:not(:disabled)
{
    background: #F9D95C;
}

.slide-surface .board-text
{
    color: var(--chalk);
    font-weight: 400;
}

.slide-surface .board-text:hover
{
    background: #F3F0E312;
}

.title-layout
{
    display: grid;
    grid-template-columns: 600px 1fr;
    gap: 26px;
    height: 100%;
    align-items: center;
}

.title-copy
{
    position: relative;
    z-index: 2;
}

.title-copy .kicker
{
    font-size: 16px;
    max-width: 500px;
    margin-bottom: 27px;
}

.title-copy h1
{
    font-size: 88px;
    line-height: 1.02;
    margin-bottom: 35px;
}

.underlined
{
    position: relative;
    display: inline-block;
}

.underlined svg
{
    position: absolute;
    bottom: -16px;
    left: -4px;
    width: 100%;
    height: 26px;
    overflow: visible;
}

.underlined path
{
    stroke: var(--marker);
    stroke-width: 5px;
    stroke-linecap: round;
    fill: none;
    stroke-dasharray: 620;
    animation: underline 600ms ease-out;
}

.title-copy .title-subhead
{
    font-size: 26px;
    max-width: 530px;
    color: var(--chalk-dim);
    margin-bottom: 27px;
}

.teacher
{
    display: flex;
    gap: 15px;
    align-items: center;
    margin: 0 0 30px;
}

.teacher img
{
    height: 56px;
    width: 56px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #F3F0E350;
}

.teacher strong
{
    display: block;
    font-size: 21px;
    font-weight: 700;
    margin-bottom: 3px;
}

.teacher span
{
    display: block;
    font-size: 18px;
    color: var(--chalk-dim);
    line-height: 1.35;
}

.title-buttons
{
    display: flex;
    align-items: center;
    gap: 9px;
}

.title-buttons .primary
{
    flex-direction: row-reverse;
}

.title-art
{
    align-self: stretch;
    position: relative;
    padding-top: 27px;
}

.photo
{
    margin: 0;
    border: 10px solid var(--panel);
    border-radius: 6px;
    transform: rotate(-1.5deg);
    position: relative;
    box-shadow: 0 8px 24px #102C2240;
}

.photo img
{
    width: 100%;
    display: block;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.taped::before, .taped::after
{
    content: "";
    height: 32px;
    width: 104px;
    background: #F6F0E25C;
    position: absolute;
    z-index: 2;
    top: -20px;
    left: 17px;
    transform: rotate(-12deg);
}

.taped::after
{
    right: 13px;
    left: auto;
    transform: rotate(14deg);
}

.lesson-chip
{
    position: relative;
    margin-left: -17px;
    margin-top: -19px;
    width: fit-content;
    padding: 13px 18px;
    background: var(--panel);
    color: var(--ink);
    border-radius: 6px;
    box-shadow: 0 4px 12px #102C2240;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 3;
    transform: rotate(1deg);
}

.mini-shelf
{
    margin-top: 30px;
    margin-left: 20px;
}

.mini-shelf .book-bars
{
    height: 130px;
    width: 100%;
}

.book-bars
{
    width: 100%;
    overflow: visible;
    display: block;
}

.book-bars .baseline, .book rect
{
    fill: none;
    stroke: var(--chalk);
    stroke-width: 3px;
    filter: url("#chalk");
}

.book
{
    transition: transform 220ms;
}

.book text
{
    fill: var(--chalk);
    font: 400 31px "JetBrains Mono", monospace;
}

.book .book-spine
{
    stroke: var(--chalk);
    stroke-width: 2px;
    opacity: .35;
}

.book.sorted rect
{
    fill: var(--chalk);
    fill-opacity: .85;
}

.book.active rect
{
    fill: var(--marker);
    stroke: var(--marker);
}

.book.active text
{
    fill: var(--marker);
}

.control-bar
{
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    border-top: 1px solid var(--line);
    background: var(--panel);
    padding: 0 16px;
}

.control-bar .icon-button
{
    width: 32px;
}

.control-bar > .icon-button + .icon-button
{
    margin-left: -8px;
}

.progress
{
    flex: 1;
    height: 6px;
    min-width: 24px;
    background: var(--line);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
}

.progress::after
{
    content: "";
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(to right, transparent 0, transparent calc(8.3333% - 1px), var(--panel) calc(8.3333% - 1px), var(--panel) 8.3333%);
    pointer-events: none;
}

.progress span
{
    display: block;
    height: 100%;
    background: var(--marker);
    transition: width 240ms;
}

.page-counter
{
    font: 400 12px "JetBrains Mono", monospace;
    white-space: nowrap;
    padding: 0 5px;
}

.page-counter i
{
    color: var(--line);
    padding: 0 2px;
    font-style: normal;
}

.draw-button, .copy-button
{
    font-size: 12px;
    padding: 8px;
}

.copy-button
{
    min-width: 89px;
}

.desktop-controls
{
    display: flex;
    gap: 3px;
    border-left: 1px solid var(--line);
    padding-left: 8px;
}

.draw-button.active
{
    background: var(--marker);
}

.mobile-top, .drawer-scrim
{
    display: none;
}

.concept-photo
{
    display: grid;
    grid-template-columns: 56% 40%;
    gap: 4%;
    align-items: center;
    height: 100%;
}

.concept-photo .photo
{
    transform: rotate(1deg);
}

.concept-photo h1
{
    font-size: 51px;
}

.concept-photo p:not(.kicker)
{
    color: var(--chalk-dim);
}

.stats
{
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin: 30px 0 22px;
}

.stats > div
{
    padding-right: 26px;
}

.stats > div + div
{
    border-left: 1px solid #F3F0E34D;
    padding-left: 30px;
}

.stats strong
{
    display: block;
    font: 500 80px Fraunces, serif;
    line-height: 1.1;
    margin-bottom: 8px;
}

.stats > div + div strong
{
    color: var(--marker);
}

.stats span
{
    font-size: 20px;
    color: var(--chalk-dim);
    display: block;
}

.slide-surface .footnote
{
    font-size: 18px;
}

.quiz-layout, .reorder-layout
{
    display: grid;
    grid-template-columns: 40% 56%;
    gap: 4%;
    align-items: center;
    height: 100%;
}

.quiz-layout h1, .reorder-layout h1
{
    font-size: 38px;
    line-height: 1.15;
    margin-bottom: 24px;
}

.question .book-bars
{
    margin-top: 35px;
}

.option-list
{
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.slide-surface .option
{
    display: flex;
    align-items: center;
    text-align: left;
    justify-content: flex-start;
    gap: 16px;
    width: 100%;
    min-height: 72px;
    border: 2px solid transparent;
    color: var(--ink);
    background: var(--panel);
    font-size: 22px;
    padding: 12px 16px;
}

.slide-surface .option:hover:not(:disabled), .slide-surface .option:focus-visible
{
    border-color: var(--marker);
    background: var(--panel);
}

.option:disabled
{
    opacity: 1;
}

.option-letter
{
    display: grid;
    place-items: center;
    height: 36px;
    width: 36px;
    border: 1px solid var(--line);
    border-radius: 50%;
    font: 400 18px "JetBrains Mono", monospace;
    flex-shrink: 0;
}

.option > span:nth-child(2)
{
    flex: 1;
}

.slide-surface .option.correct-answer
{
    border-color: var(--mint);
}

.slide-surface .option.chosen.correct
{
    background: var(--mint);
    animation: correct-pulse 320ms;
}

.slide-surface .option.chosen.incorrect
{
    background: var(--clay);
    animation: incorrect-pulse 320ms;
}

.mono
{
    font-family: "JetBrains Mono", monospace;
}

.feedback
{
    padding: 18px 22px;
    background: var(--board-deep);
    margin-top: 20px;
    border-radius: 10px;
    animation: fade-in 160ms;
}

.feedback > strong
{
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
}

.feedback.is-correct > strong
{
    color: var(--mint);
}

.feedback.is-wrong > strong
{
    color: var(--clay);
}

.feedback p
{
    font-size: 20px;
    margin: 8px 0 12px;
    color: var(--chalk-dim);
    line-height: 1.35;
}

.feedback > div
{
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.slide-surface .feedback button
{
    font-size: 18px;
    min-height: 40px;
    padding: 9px 13px;
}

.stepper-slide h1
{
    font-size: 44px;
    max-width: 880px;
}

.stepper-slide .kicker
{
    margin-bottom: 18px;
}

.step-label
{
    text-align: right;
    font: 400 18px "JetBrains Mono", monospace;
    color: var(--chalk-dim);
    margin: -20px 0 0;
}

#step-diagram
{
    margin: 0 0 18px;
}

#step-diagram .book-bars
{
    height: 300px;
}

.step-bottom
{
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: start;
    gap: 40px;
}

.step-bottom > p
{
    max-width: 650px;
    font-size: 24px;
}

.step-controls
{
    display: flex;
    justify-content: center;
    gap: 10px;
}

.step-dots
{
    display: flex;
    justify-content: center;
    margin: 13px 0;
    gap: 10px;
}

.slide-surface .step-dots button
{
    width: 9px;
    height: 9px;
    min-height: 9px;
    background: #F3F0E34D;
    padding: 0;
    border-radius: 50%;
}

.step-dots button.active
{
    background: var(--marker);
}

.shift-counter, .legend
{
    font: 400 18px "JetBrains Mono", monospace;
    color: var(--chalk-dim);
}

.legend
{
    display: flex;
    gap: 26px;
    font-size: 16px;
    margin-top: 12px;
}

.legend span
{
    display: flex;
    align-items: center;
    gap: 8px;
}

.legend i
{
    height: 12px;
    width: 12px;
    border: 1px solid var(--chalk);
    border-radius: 2px;
}

.legend .sorted-key
{
    background: var(--chalk);
}

.legend .active-key
{
    background: var(--marker);
    border-color: var(--marker);
}

.reorder-layout
{
    grid-template-columns: 31% 65%;
}

.reorder-row
{
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 69px;
    border: 2px solid transparent;
    border-radius: 10px;
    background: var(--panel);
    color: var(--ink);
    margin-bottom: 10px;
    padding: 5px 10px;
}

.slide-surface .reorder-row button
{
    padding: 3px;
    min-height: 28px;
    width: 30px;
    height: 28px;
}

.reorder-text
{
    flex: 1;
    font-size: 21px;
    line-height: 1.15;
}

.position
{
    font: 400 18px "JetBrains Mono", monospace;
    color: var(--muted);
}

.reorder-arrows
{
    display: flex;
    flex-direction: column;
}

.reorder-row .grip
{
    cursor: grab;
    touch-action: none;
    color: var(--muted);
}

.reorder-row.dragging
{
    box-shadow: 0 6px 24px #122B2360;
    border-color: var(--marker);
}

.reorder-row.drop-target
{
    border-bottom-color: var(--marker);
}

.reorder-row.correct
{
    border-color: var(--mint);
}

.reorder-row.incorrect
{
    border-color: var(--clay);
}

.check-button
{
    margin-top: 15px;
}

.reorder-content .feedback
{
    margin-top: 10px;
    padding: 13px 18px;
}

.reorder-content .feedback p
{
    font-size: 18px;
}

.fill-layout
{
    max-width: 1040px;
    margin: 10px auto;
}

.fill-layout h1
{
    font-size: 46px;
}

.fill-layout .fill-sentence
{
    font: 500 38px / 1.65 Fraunces, serif;
    margin: 25px 0;
}

.input-wrap
{
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.input-wrap input
{
    width: 96px;
    height: 50px;
    background: transparent;
    border: 0;
    border-bottom: 3px solid var(--marker);
    border-radius: 0;
    color: var(--chalk);
    text-align: center;
    font: 400 28px "JetBrains Mono", monospace;
}

.input-wrap input.correct
{
    border-color: var(--mint);
}

.input-wrap input.incorrect
{
    border-color: var(--clay);
}

.fill-layout .feedback
{
    margin-top: 25px;
}

.code-slide h1
{
    font-size: 40px;
    margin: 0 0 12px;
}

.code-slide .kicker
{
    margin-bottom: 12px;
}

.code-slide .code-task
{
    font-size: 22px;
    color: var(--chalk-dim);
    margin-bottom: 22px;
}

.code-panes
{
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    gap: 16px;
    height: 425px;
}

.editor-pane, .console-pane
{
    min-width: 0;
    border: 1px solid #F3F0E326;
    border-radius: 10px;
    overflow: hidden;
    background: var(--board-deep);
    display: grid;
    grid-template-rows: 44px minmax(0, 1fr);
}

.pane-toolbar
{
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #F3F0E326;
    padding: 0 14px;
    font: 400 16px "JetBrains Mono", monospace;
}

.pane-toolbar > div
{
    display: flex;
    gap: 7px;
    align-items: center;
}

.slide-surface .pane-toolbar button
{
    min-height: 30px;
    height: 30px;
    padding: 4px 11px;
    font-size: 16px;
    border-radius: 5px;
}

.pane-toolbar button svg
{
    width: 16px;
    height: 16px;
}

#editor
{
    min-height: 0;
    overflow: hidden;
}

.console-pane
{
    background: var(--console);
}

#code-status
{
    font-size: 12px;
    color: var(--chalk-dim);
    max-width: 70%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#console-log
{
    padding: 16px;
    overflow: auto;
    font: 400 18px / 1.7 "JetBrains Mono", monospace;
}

.slide-surface .console-empty
{
    font: 400 17px / 1.5 "JetBrains Mono", monospace;
    color: var(--chalk-dim);
}

.log-line
{
    display: flex;
    gap: 8px;
    overflow-wrap: anywhere;
    white-space: pre-wrap;
}

.log-line.error
{
    color: var(--clay);
}

.log-line svg
{
    margin-top: 6px;
    width: 16px;
    height: 16px;
}

.slide-surface .sandbox-note
{
    font: 400 13px "JetBrains Mono", monospace;
    color: var(--chalk-dim);
    margin: 13px 0 0;
    text-align: right;
    letter-spacing: .06em;
}

.work-layout
{
    display: grid;
    grid-template-columns: 65% 31%;
    gap: 4%;
    align-items: center;
    margin-top: 45px;
}

.work-bars > div
{
    margin-bottom: 25px;
}

.work-bars p
{
    font-size: 22px;
    margin-bottom: 9px;
}

.work-track
{
    display: flex;
    align-items: center;
    gap: 15px;
}

.work-track span
{
    display: block;
    height: 40px;
    background: #F3F0E3D9;
    border: 2px solid var(--chalk);
    border-radius: 3px;
    animation: grow 400ms ease-out;
    transform-origin: left center;
}

.work-track b
{
    font: 400 22px "JetBrains Mono", monospace;
}

.callout
{
    padding: 30px 24px;
    background: var(--board-deep);
    border-radius: 10px;
}

.callout strong
{
    font: 500 68px Fraunces, serif;
    letter-spacing: -.04em;
    color: var(--marker);
}

.callout span
{
    display: block;
    font-size: 23px;
    line-height: 1.5;
    margin-top: 15px;
    color: var(--chalk-dim);
}

.slide-surface .work-conclusion
{
    font-size: 24px;
    color: var(--chalk-dim);
    margin-top: 22px;
}

.board-layout
{
    display: grid;
    grid-template-columns: 34% 62%;
    gap: 4%;
    align-items: center;
    height: 100%;
}

.board-layout h1
{
    font-size: 48px;
}

.board-layout p:not(.kicker)
{
    color: var(--chalk-dim);
}

.board-layout .signature
{
    margin-top: 24px;
    font: italic 500 24px Fraunces, serif;
}

.board-layout .book-bars
{
    margin-top: 90px;
}

.recap > .slide-content
{
    padding-top: 45px;
}

.recap .kicker
{
    margin-bottom: 16px;
}

.recap h1
{
    font-size: 48px;
    margin-bottom: 25px;
}

.recap-layout
{
    display: grid;
    grid-template-columns: 29% 31% minmax(0, 34%);
    gap: 3%;
}

.recap-score
{
    font: 500 96px Fraunces, serif;
    color: var(--marker);
    margin-bottom: 12px;
    line-height: 1.1;
}

.recap-layout p
{
    font-size: 20px;
    color: var(--chalk-dim);
}

.check-chips
{
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 24px 0;
}

.check-chips a
{
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 10px;
    border: 1px solid #F3F0E350;
    border-radius: 6px;
    font-size: 18px;
    text-decoration: none;
}

.check-chips .correct
{
    color: var(--mint);
    border-color: var(--mint);
}

.check-chips .incorrect
{
    color: var(--clay);
    border-color: var(--clay);
}

.recap-layout button
{
    font-size: 18px;
    margin-bottom: 10px;
}

.takeaways > div
{
    display: flex;
    gap: 15px;
    padding: 20px 0;
    border-bottom: 1px solid #F3F0E333;
}

.takeaways > div > span
{
    font: 400 16px "JetBrains Mono", monospace;
    color: var(--marker);
    padding-top: 4px;
}

.takeaways p
{
    margin: 0;
    color: var(--chalk);
}

.takeaways .kicker
{
    font-size: 14px;
    margin: 16px 0 0;
}

.homework
{
    border-radius: 7px;
    overflow: hidden;
    background: var(--panel);
    color: var(--ink);
}

.homework > img
{
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block;
}

.homework > div
{
    padding: 16px 20px;
}

.homework p
{
    color: var(--ink);
    font-size: 18px;
    line-height: 1.3;
    margin: 0 0 13px;
}

.homework .kicker
{
    color: var(--muted);
    font-size: 13px;
    margin: 0 0 8px;
}

.homework .next-lesson
{
    border-top: 1px solid var(--line);
    padding-top: 10px;
    font-weight: 700;
    font-size: 16px;
}

.office
{
    display: flex;
    gap: 8px;
    align-items: center;
}

.office img
{
    width: 30px;
    height: 30px;
}

.office p
{
    font-size: 12px;
    color: var(--muted);
    margin: 0;
}

#marks
{
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 6;
}

.drawing #marks
{
    pointer-events: auto;
    touch-action: none;
    cursor: crosshair;
}

.draw-toolbar
{
    position: absolute;
    z-index: 15;
    bottom: 17px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    padding: 7px 10px;
    gap: 4px;
    border: 1px solid var(--line);
    border-radius: 40px;
    background: var(--panel);
    box-shadow: 0 8px 30px #25302A29;
    animation: fade-in 120ms;
    white-space: nowrap;
}

.draw-toolbar .active
{
    background: var(--marker);
}

.tool-divider
{
    width: 1px;
    height: 22px;
    background: var(--line);
    margin: 0 4px;
}

.swatch
{
    width: 26px;
    height: 26px;
    min-height: 26px;
    border-radius: 50%;
    padding: 0;
    margin: 0 3px;
    background: var(--swatch);
    border: 1px solid #25302A44;
}

.swatch.selected
{
    outline: 2px solid var(--ink);
    outline-offset: 3px;
}

.swatch:hover:not(:disabled)
{
    background: var(--swatch);
}

dialog
{
    color: var(--ink);
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 28px;
    width: min(640px, calc(100vw - 32px));
    max-height: 90dvh;
    overflow: auto;
    box-shadow: 0 24px 80px #122B2340;
}

dialog::backdrop
{
    background: #25302A73;
}

.dialog-heading
{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 20px;
}

.dialog-heading h2
{
    font: 500 29px Fraunces, serif;
    margin: 0;
}

.shortcut-grid
{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px 20px;
}

.shortcut-grid > div
{
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    font-size: 14px;
}

kbd
{
    font: 400 12px "JetBrains Mono", monospace;
    background: var(--paper);
    border: 1px solid var(--line);
    padding: 5px 8px;
    border-radius: 6px;
}

.presenting
{
    grid-template-columns: minmax(0, 1fr) !important;
}

.presenting .sidebar
{
    display: none;
}

.sr-only
{
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    position: absolute;
    overflow: hidden;
    clip-path: inset(50%);
}

@keyframes slide-in
{
    from { opacity: 0; translate: 12px 0; }
    to { opacity: 1; translate: 0 0; }
}

@keyframes fade-in
{
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes underline
{
    from { stroke-dashoffset: 620; }
    to { stroke-dashoffset: 0; }
}

@keyframes grow
{
    from { transform: scaleX(0); }
    to { transform: scaleX(1); }
}

@keyframes correct-pulse
{
    50% { box-shadow: 0 0 0 8px #8FD3A840; }
}

@keyframes incorrect-pulse
{
    50% { box-shadow: 0 0 0 8px #E58E7340; }
}

@media (max-width: 1050px) and (min-width: 768px)
{
    #app { grid-template-columns: 240px minmax(0, 1fr); }
    .outline-row { font-size: 12px; gap: 6px; padding-left: 14px; }
    .sidebar-header { padding-left: 18px; padding-right: 18px; }
    .control-bar { gap: 5px; padding: 0 9px; }
    .draw-button span, .copy-button span { display: none; }
    .copy-button { min-width: 36px; }
}

@media (max-width: 767px)
{
    #app, #app.collapsed
    {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: 52px minmax(0, 1fr);
    }

    .mobile-top
    {
        display: flex;
        align-items: center;
        gap: 9px;
        padding: 0 13px 0 8px;
        background: var(--panel);
        border-bottom: 1px solid var(--line);
    }

    .mobile-top > strong
    {
        font: 500 18px Fraunces, serif;
        flex: 1;
        white-space: nowrap;
        text-overflow: ellipsis;
        overflow: hidden;
    }

    .sidebar, .collapsed .sidebar
    {
        display: none;
        position: fixed;
        inset: 0 auto 0 0;
        width: min(304px, 85vw);
    }

    .drawer-open .sidebar
    {
        display: flex;
        animation: slide-in 180ms ease-out;
    }

    .collapsed .sidebar-header, .collapsed .sidebar-footer, .collapsed .outline h3,
    .collapsed .outline-title, .collapsed .type-icon
    {
        display: revert;
    }

    .collapsed .outline
    {
        padding-top: 0;
    }

    .collapsed .outline-row
    {
        padding: 0 14px 0 20px;
        gap: 9px;
    }

    .collapsed .rail-expand
    {
        display: none;
    }

    .drawer-open .drawer-scrim
    {
        display: block;
        position: fixed;
        inset: 0;
        width: 100%;
        height: 100%;
        border-radius: 0;
        background: #25302A73;
        z-index: 19;
    }

    .sidebar-header
    {
        padding: 20px 22px 13px;
    }

    .sidebar .course
    {
        margin-top: 13px;
    }

    .sidebar h2
    {
        margin-bottom: 14px;
    }

    .outline-row
    {
        height: 44px;
        font-size: 14px;
    }

    .sidebar-footer
    {
        padding-top: 12px;
    }

    .main
    {
        grid-template-rows: minmax(0, 1fr) 62px;
    }

    .stage-area
    {
        display: block;
        padding: 0;
        background: var(--board);
    }

    .stage-eyebrow, .stage-note, .ledge
    {
        display: none;
    }

    .canvas-size
    {
        width: 100%;
        height: 100%;
        box-shadow: none;
        border-radius: 0;
    }

    .slide-surface
    {
        width: 100%;
        height: 100%;
        overflow-y: auto;
        overflow-x: hidden;
        overscroll-behavior: contain;
        border-radius: 0;
        scrollbar-width: thin;
    }

    .slide-content, .recap > .slide-content
    {
        padding: 28px 20px 40px;
        height: auto;
        min-height: 100%;
    }

    .slide-surface h1, .title-copy h1, .concept-photo h1, .stepper-slide h1, .fill-layout h1,
    .code-slide h1, .board-layout h1, .recap h1
    {
        font-size: 32px;
        line-height: 1.1;
        margin-bottom: 20px;
    }

    .slide-surface p, .title-copy .title-subhead, .code-slide .code-task,
    .step-bottom > p, .slide-surface .work-conclusion
    {
        font-size: 17px;
        line-height: 1.45;
        margin-bottom: 20px;
    }

    .slide-surface .kicker, .title-copy .kicker
    {
        font-size: 11px;
        line-height: 1.6;
        margin-bottom: 18px;
        letter-spacing: .065em;
    }

    .slide-surface button, button, .icon-button
    {
        min-height: 44px;
    }

    .slide-surface button
    {
        font-size: 16px;
        padding: 10px 14px;
    }

    .title-layout, .concept-photo, .quiz-layout, .reorder-layout, .board-layout,
    .recap-layout, .work-layout, .step-bottom
    {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        height: auto;
        gap: 25px;
    }

    .title-layout
    {
        gap: 30px;
    }

    .title-copy h1
    {
        font-size: 50px;
        line-height: 1.02;
        margin-bottom: 30px;
    }

    .title-copy h1 br
    {
        display: none;
    }

    .title-copy .title-subhead
    {
        max-width: 320px;
        font-size: 18px;
        margin-bottom: 22px;
    }

    .underlined svg
    {
        bottom: -15px;
        height: 20px;
    }

    .teacher
    {
        gap: 12px;
        margin-bottom: 23px;
    }

    .teacher img
    {
        width: 44px;
        height: 44px;
    }

    .teacher strong
    {
        font-size: 16px;
    }

    .teacher span
    {
        font-size: 13px;
    }

    .title-buttons
    {
        gap: 5px;
        flex-wrap: wrap;
    }

    .title-buttons button
    {
        font-size: 14px;
        padding: 10px 12px;
    }

    .title-art
    {
        padding: 0;
    }

    .photo, .concept-photo .photo
    {
        transform: none;
        border-width: 7px;
        width: 100%;
    }

    .title-art .photo img
    {
        aspect-ratio: 16 / 10;
    }

    .taped::before, .taped::after
    {
        width: 70px;
        height: 23px;
        top: -14px;
    }

    .lesson-chip
    {
        margin: -18px auto 0;
        padding: 10px 12px;
        font-size: 12px;
        gap: 7px;
        transform: none;
    }

    .lesson-chip svg
    {
        width: 16px;
    }

    .mini-shelf
    {
        margin: 18px 10px 0;
    }

    .mini-shelf .book-bars
    {
        height: 90px;
    }

    .control-bar
    {
        position: relative;
        gap: 5px;
        padding: 5px 10px;
        justify-content: space-between;
    }

    .control-bar .icon-button
    {
        height: 44px;
        width: 44px;
        min-width: 44px;
    }

    .control-bar > .icon-button + .icon-button
    {
        margin-left: 0;
    }

    .control-bar .progress
    {
        position: absolute;
        top: 0;
        height: 3px;
        left: 0;
        right: 0;
        border-radius: 0;
    }

    .page-counter
    {
        font-size: 11px;
        padding: 0;
    }

    .draw-button, .copy-button
    {
        font-size: 12px;
        padding: 6px 7px;
        gap: 5px;
        min-height: 44px;
        min-width: 44px;
    }

    .copy-button span
    {
        display: none;
    }

    .desktop-controls
    {
        display: none;
    }

    .stats
    {
        margin: 24px 0;
    }

    .stats strong
    {
        font-size: 55px;
    }

    .stats span
    {
        font-size: 14px;
    }

    .stats > div
    {
        padding-right: 16px;
    }

    .stats > div + div
    {
        padding-left: 22px;
    }

    .slide-surface .footnote
    {
        font-size: 13px;
    }

    .quiz-layout h1, .reorder-layout h1
    {
        font-size: 26px;
        line-height: 1.2;
        margin-bottom: 0;
    }

    .option-list
    {
        gap: 12px;
    }

    .slide-surface .option
    {
        min-height: 62px;
        padding: 10px 12px;
        gap: 12px;
        font-size: 17px;
    }

    .option-letter
    {
        width: 30px;
        height: 30px;
        font-size: 14px;
    }

    .feedback
    {
        padding: 16px;
    }

    .feedback > strong
    {
        font-size: 17px;
    }

    .feedback p, .reorder-content .feedback p
    {
        font-size: 15px;
        margin: 10px 0;
    }

    .slide-surface .feedback button
    {
        font-size: 14px;
        min-height: 44px;
        padding: 9px;
    }

    .question .book-bars
    {
        height: 135px;
        margin-top: 23px;
    }

    .step-label
    {
        font-size: 12px;
        margin: 0 0 15px;
        text-align: left;
    }

    #step-diagram .book-bars
    {
        height: auto;
        margin: 35px 0;
    }

    .step-bottom
    {
        gap: 0;
    }

    .step-bottom > div
    {
        align-self: center;
    }

    .shift-counter
    {
        font-size: 14px;
    }

    .step-dots
    {
        gap: 0;
    }

    .slide-surface .step-dots button
    {
        width: 30px;
        height: 44px;
        min-height: 44px;
        background: radial-gradient(circle, #F3F0E350 4px, transparent 5px);
    }

    .slide-surface .step-dots button.active
    {
        background: radial-gradient(circle, var(--marker) 4px, transparent 5px);
    }

    .legend
    {
        flex-wrap: wrap;
        gap: 13px;
        font-size: 11px;
        margin-top: 24px;
    }

    .reorder-row
    {
        gap: 7px;
        min-height: 88px;
        padding: 5px;
    }

    .reorder-text
    {
        font-size: 15px;
        line-height: 1.25;
    }

    .position
    {
        font-size: 13px;
    }

    .slide-surface .reorder-row button
    {
        min-width: 44px;
        min-height: 44px;
    }

    .reorder-row .grip
    {
        min-width: 24px;
        width: 24px;
    }

    .reorder-row > svg
    {
        width: 14px;
    }

    .fill-layout
    {
        margin: 0;
    }

    .fill-layout .fill-sentence
    {
        font-size: 26px;
        line-height: 1.7;
    }

    .input-wrap input
    {
        width: 75px;
        font-size: 24px;
    }

    .code-panes
    {
        display: flex;
        flex-direction: column;
        gap: 15px;
        height: auto;
    }

    .editor-pane
    {
        height: 344px;
        flex-shrink: 0;
    }

    .console-pane
    {
        min-height: 224px;
        max-height: 400px;
    }

    .pane-toolbar
    {
        font-size: 12px;
        padding: 0 10px;
    }

    #editor .cm-editor
    {
        font-size: 14px !important;
    }

    #console-log
    {
        font-size: 13px;
        min-height: 180px;
        padding: 13px;
    }

    .slide-surface .console-empty
    {
        font-size: 13px;
    }

    #code-status
    {
        font-size: 10px;
    }

    .slide-surface .sandbox-note
    {
        font-size: 10px;
        margin-top: 14px;
    }

    .work-layout
    {
        margin-top: 30px;
        gap: 15px;
    }

    .work-bars p
    {
        font-size: 17px;
        margin-bottom: 8px;
    }

    .work-track span
    {
        height: 30px;
    }

    .work-track b
    {
        font-size: 16px;
    }

    .callout
    {
        padding: 20px;
    }

    .callout strong
    {
        font-size: 55px;
    }

    .callout span
    {
        font-size: 17px;
        margin-top: 5px;
    }

    .board-layout .signature
    {
        font-size: 20px;
        margin-top: 15px;
    }

    .board-layout .book-bars
    {
        margin-top: 35px;
    }

    .recap-layout
    {
        gap: 30px;
    }

    .recap-score
    {
        font-size: 75px;
    }

    .recap-layout p, .recap-layout button
    {
        font-size: 17px;
    }

    .check-chips a
    {
        font-size: 14px;
        min-height: 44px;
    }

    .takeaways .kicker
    {
        font-size: 11px;
    }

    .takeaways > div
    {
        padding: 16px 0;
    }

    .takeaways > div > span
    {
        font-size: 13px;
    }

    .homework .kicker
    {
        font-size: 11px;
    }

    .homework .office p
    {
        font-size: 12px;
        margin: 0;
    }

    .draw-toolbar
    {
        width: 340px;
        max-width: calc(100% - 20px);
        flex-wrap: wrap;
        justify-content: center;
        border-radius: 16px;
        bottom: 10px;
        gap: 4px;
        padding: 8px;
    }

    .draw-toolbar .icon-button, .draw-toolbar .swatch
    {
        width: 44px;
        min-height: 44px;
        height: 44px;
    }

    .draw-toolbar .swatch
    {
        background: radial-gradient(circle, var(--swatch) 11px, transparent 12px);
        border: 0;
        margin: 0;
    }

    .draw-toolbar .swatch.selected
    {
        outline-offset: -7px;
        border-radius: 50%;
    }

    .tool-divider
    {
        display: none;
    }

    .draw-toolbar .done-button
    {
        font-size: 13px;
    }

    .presenting .mobile-top
    {
        display: flex;
    }

    .shortcut-grid
    {
        gap: 15px 12px;
    }
}

@media (prefers-reduced-motion: reduce)
{
    *, *::before, *::after
    {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}
