@font-face
{
    font-family: Fraunces;
    src: url("./fonts/fraunces-latin-500-normal.woff2") format("woff2");
    font-weight: 500;
    font-display: swap;
}
@font-face
{
    font-family: Fraunces;
    src: url("./fonts/fraunces-latin-600-normal.woff2") format("woff2");
    font-weight: 600;
    font-display: swap;
}
@font-face
{
    font-family: "DM Sans";
    src: url("./fonts/dm-sans-latin-400-normal.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
}
@font-face
{
    font-family: "DM Sans";
    src: url("./fonts/dm-sans-latin-500-normal.woff2") format("woff2");
    font-weight: 500;
    font-display: swap;
}
@font-face
{
    font-family: "DM Sans";
    src: url("./fonts/dm-sans-latin-600-normal.woff2") format("woff2");
    font-weight: 600;
    font-display: swap;
}
:root
{
    color-scheme: dark;
    --night: #0b1917;
    --spruce: #132b26;
    --raised: #1b3932;
    --line: #315047;
    --ivory: #f3efe3;
    --mist: #b8c8be;
    --brass: #d2a85f;
    font-family: "DM Sans", sans-serif;
    color: var(--ivory);
    background: var(--night);
    font-synthesis: none;
}
*
{
    box-sizing: border-box;
}
body
{
    margin: 0;
}
button, input
{
    font: inherit;
}
button, a, input, canvas
{
    -webkit-tap-highlight-color: transparent;
}
button
{
    color: inherit;
    cursor: pointer;
    border: 1px solid var(--line);
    background: transparent;
    transition: background 140ms, border-color 140ms, color 140ms;
}
button:hover
{
    background: var(--raised);
    border-color: var(--mist);
}
:focus-visible
{
    outline: 2px solid var(--ivory);
    outline-offset: 4px;
    box-shadow: 0 0 0 6px var(--night);
}
header
{
    height: 68px;
    border-bottom: 1px solid var(--line);
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.brand
{
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: Fraunces, serif;
    font-weight: 600;
    font-size: 24px;
    letter-spacing: -.5px;
}
.brand svg
{
    width: 31px;
    height: 36px;
    color: var(--brass);
}
.header-right
{
    display: flex;
    align-items: center;
    gap: 28px;
    font-size: 12px;
    color: var(--mist);
}
.help-button
{
    border: 0;
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    padding: 0 6px;
    border-radius: 6px;
}
.icon
{
    width: 19px;
    height: 19px;
    flex-shrink: 0;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.65;
    stroke-linecap: round;
    stroke-linejoin: round;
}
main
{
    max-width: 1680px;
    margin: auto;
    padding: 28px 32px;
    display: grid;
    grid-template-columns: minmax(210px, 280px) minmax(340px, 1fr) 304px;
    gap: 24px;
    min-height: calc(100svh - 132px);
    align-items: stretch;
}
.intro
{
    align-self: center;
    padding-bottom: 30px;
}
.eyebrow
{
    color: var(--brass);
    text-transform: uppercase;
    font-size: 10px;
    line-height: 1.8;
    letter-spacing: .15em;
    max-width: 230px;
    margin: 0 0 24px;
}
h1
{
    font-family: Fraunces, serif;
    font-size: clamp(46px, 4.4vw, 68px);
    font-weight: 500;
    line-height: 1.02;
    letter-spacing: -.045em;
    margin: 0 0 24px;
}
h1 em
{
    font-style: normal;
    color: var(--brass);
}
.intro-copy
{
    color: var(--mist);
    font-size: 13px;
    line-height: 1.85;
    max-width: 260px;
    margin: 0;
}
.cues
{
    list-style: none;
    padding: 0;
    margin: 40px 0 0;
    display: grid;
    gap: 24px;
}
.cues li
{
    display: grid;
    grid-template-columns: 25px 1fr;
    gap: 8px;
}
.cue-number
{
    color: var(--brass);
    font-size: 10px;
    padding-top: 3px;
}
.cues strong
{
    font-weight: 500;
    font-size: 12px;
}
.cues p
{
    font-size: 11px;
    line-height: 1.6;
    color: var(--mist);
    margin: 5px 0 0;
    max-width: 190px;
}
.mobile-cues
{
    display: none;
}
.stage
{
    min-width: 0;
    min-height: 620px;
    border: 1px solid #28443c;
    border-radius: 18px;
    overflow: hidden;
    position: relative;
    background: var(--night);
}
.stage canvas
{
    width: 100%;
    height: 100%;
    display: block;
    position: absolute;
    inset: 0;
    cursor: grab;
    touch-action: none;
}
.stage canvas:active
{
    cursor: grabbing;
}
.stage canvas:focus-visible
{
    outline-offset: -6px;
    box-shadow: none;
}
.stage-top
{
    position: absolute;
    z-index: 1;
    top: 24px;
    left: 24px;
    right: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    pointer-events: none;
}
.stage-overline
{
    text-transform: uppercase;
    font-size: 8px;
    letter-spacing: .2em;
    color: #a4b8ac;
}
.motion-status
{
    font-size: 10px;
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--mist);
}
.motion-status::before
{
    content: "";
    height: 5px;
    width: 5px;
    background: var(--brass);
    border-radius: 50%;
}
.motion-status[data-rest="true"]::before
{
    background: #9bb9a9;
}
.stage-bottom
{
    position: absolute;
    bottom: 23px;
    left: 24px;
    pointer-events: none;
}
.scene-type
{
    font-size: 8px;
    letter-spacing: .18em;
    color: var(--brass);
    text-transform: uppercase;
}
.scene-title
{
    font-family: Fraunces, serif;
    font-size: 23px;
    font-weight: 500;
    margin: 5px 0 0;
}
.drag-hint
{
    position: absolute;
    bottom: 24px;
    right: 24px;
    font-size: 10px;
    color: var(--mist);
    pointer-events: none;
    display: flex;
    align-items: center;
    gap: 7px;
}
.workbench
{
    border: 1px solid var(--line);
    background: var(--spruce);
    border-radius: 18px;
    align-self: start;
    padding: 23px 20px;
}
.workbench h2
{
    margin: 0 0 18px;
    font-size: 14px;
    font-weight: 500;
}
.section-number
{
    font-size: 9px;
    color: var(--brass);
    margin-right: 10px;
}
.scene-choices
{
    display: grid;
    gap: 10px;
}
.scene-choice
{
    border-radius: 8px;
    padding: 7px 10px;
    display: flex;
    gap: 12px;
    align-items: center;
    text-align: left;
    min-height: 72px;
    width: 100%;
    position: relative;
}
.scene-choice[aria-pressed="true"]
{
    border-color: var(--brass);
    box-shadow: inset 0 0 0 1px var(--brass);
    background: var(--raised);
}
.thumbnail
{
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}
.choice-name
{
    display: block;
    font-size: 12px;
    font-weight: 500;
    padding-right: 12px;
}
.choice-type
{
    display: block;
    color: var(--mist);
    font-size: 10px;
    margin-top: 5px;
}
.selection-check
{
    position: absolute;
    right: 9px;
    top: 10px;
    width: 13px;
    height: 13px;
    color: var(--brass);
}
.scene-choice[aria-pressed="false"] .selection-check
{
    display: none;
}
.message-section
{
    margin-top: 26px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
}
.message-section label
{
    font-size: 12px;
    display: block;
    margin-bottom: 13px;
}
.input-wrap
{
    position: relative;
}
input
{
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--night);
    color: var(--ivory);
    min-height: 47px;
    width: 100%;
    padding: 0 12px;
    font-size: 12px;
}
.field-meta
{
    display: flex;
    gap: 5px;
    justify-content: space-between;
    color: var(--mist);
    font-size: 9px;
    line-height: 1.5;
    margin-top: 9px;
}
#message-count
{
    white-space: nowrap;
}
.actions
{
    display: grid;
    gap: 10px;
    margin-top: 25px;
}
.action
{
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border-radius: 9px;
    font-size: 12px;
    font-weight: 500;
}
.primary
{
    background: var(--brass);
    color: var(--night);
    border-color: var(--brass);
}
.primary:hover
{
    background: #e6bd77;
    border-color: #e6bd77;
}
.bench-foot
{
    color: var(--mist);
    font-size: 10px;
    line-height: 1.7;
    text-align: center;
    margin: 18px 0 0;
}
.keyboard-hint
{
    color: #b8c8be;
    display: flex;
    justify-content: center;
    gap: 8px;
    font-size: 9px;
    padding-top: 18px;
    margin-top: 20px;
    border-top: 1px solid var(--line);
}
kbd
{
    border: 1px solid #567267;
    border-radius: 3px;
    padding: 1px 5px;
    font: inherit;
}
.sensor-status
{
    font-size: 11px;
    line-height: 1.7;
    color: var(--mist);
}
footer
{
    max-width: 1680px;
    margin: auto;
    border-top: 1px solid #203a32;
    padding: 20px 32px;
    display: flex;
    justify-content: space-between;
    color: var(--mist);
    font-size: 10px;
    gap: 20px;
}
a
{
    color: var(--mist);
    text-underline-offset: 4px;
    text-decoration-color: #567267;
}
footer a
{
    min-height: 44px;
    display: flex;
    align-items: center;
    margin: -15px 0;
}
dialog
{
    background: var(--spruce);
    border: 1px solid var(--line);
    color: var(--ivory);
    border-radius: 12px;
    padding: 28px;
    width: min(460px, calc(100% - 32px));
    max-height: 78svh;
}
dialog::backdrop
{
    background: #07120fe8;
}
dialog h2
{
    font: 500 31px/1.1 Fraunces, serif;
    margin: 0 30px 28px 0;
}
dialog h3
{
    font-size: 13px;
    font-weight: 500;
    color: var(--brass);
    margin: 20px 0 7px;
}
dialog p
{
    font-size: 12px;
    line-height: 1.8;
    color: var(--mist);
}
dialog .action
{
    width: 100%;
    margin-top: 24px;
}
.close-icon
{
    position: absolute;
    right: 14px;
    top: 14px;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 8px;
}
.dialog-credit
{
    font-size: 10px;
    display: inline-flex;
    align-items: center;
    min-height: 44px;
}
.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;
}
.fallback
{
    display: grid;
    place-items: center;
    height: 100%;
    position: absolute;
    inset: 0;
    padding: 40px 20px 90px;
}
.fallback > svg
{
    width: min(100%, 450px);
    max-height: 100%;
}
.fallback-note
{
    position: absolute;
    bottom: 85px;
    font-size: 10px;
    text-align: center;
    left: 20px;
    right: 20px;
    color: var(--mist);
}
.fallback.burst .fallback-flakes
{
    animation: flurry 600ms ease-out;
}
@keyframes flurry
{
    from { transform: translateY(60px); opacity: .15; }
    30% { transform: translateY(-20px); opacity: 1; }
    to { transform: translateY(0); opacity: .8; }
}
@media (max-width: 1240px) and (min-width: 901px)
{
    main
    {
        grid-template-columns: 218px minmax(320px, 1fr) 276px;
        gap: 20px;
        padding: 28px 24px;
    }
    .workbench
    {
        padding: 22px 16px;
    }
    .stage-overline
    {
        display: none;
    }
    .stage-top
    {
        justify-content: flex-end;
    }
}
@media (max-width: 900px)
{
    header
    {
        height: 56px;
        padding: 0 16px;
    }
    .brand
    {
        font-size: 22px;
        gap: 8px;
    }
    .brand svg
    {
        width: 26px;
        height: 30px;
    }
    .tagline
    {
        display: none;
    }
    main
    {
        display: flex;
        flex-direction: column;
        padding: 25px 16px 24px;
        gap: 20px;
        min-height: 0;
        max-width: 620px;
    }
    .intro
    {
        padding: 0;
        align-self: stretch;
    }
    .eyebrow
    {
        max-width: none;
        font-size: 9px;
        margin-bottom: 12px;
    }
    h1
    {
        font-size: 38px;
        max-width: 350px;
        margin-bottom: 13px;
    }
    .intro-copy
    {
        font-size: 12px;
        line-height: 1.7;
        max-width: 450px;
    }
    .cues
    {
        display: none;
    }
    .mobile-cues
    {
        display: block;
        font-size: 9px;
        color: var(--brass);
        letter-spacing: .09em;
        margin: 13px 0 0;
    }
    .stage
    {
        height: 340px;
        min-height: 340px;
        flex: none;
    }
    .stage-top
    {
        top: 16px;
        left: 16px;
        right: 16px;
    }
    .stage-overline
    {
        font-size: 6px;
        max-width: 100px;
        line-height: 1.6;
    }
    .motion-status
    {
        font-size: 8px;
    }
    .stage-bottom
    {
        bottom: 15px;
        left: 16px;
    }
    .scene-title
    {
        font-size: 18px;
    }
    .scene-type
    {
        font-size: 7px;
    }
    .drag-hint
    {
        bottom: 17px;
        right: 16px;
        font-size: 8px;
    }
    .drag-hint .icon
    {
        width: 14px;
    }
    .workbench
    {
        width: 100%;
        padding: 20px 15px;
    }
    .workbench h2
    {
        margin-bottom: 15px;
    }
    .scene-choices
    {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
    }
    .scene-choice
    {
        flex-direction: column;
        text-align: center;
        gap: 5px;
        padding: 8px 4px 11px;
        min-height: 110px;
    }
    .thumbnail
    {
        height: 39px;
        width: 44px;
    }
    .choice-name
    {
        padding: 0;
        font-size: 10px;
        line-height: 1.4;
    }
    .choice-type
    {
        font-size: 8px;
        margin-top: 3px;
    }
    .selection-check
    {
        right: 5px;
        top: 5px;
        width: 10px;
    }
    .message-section
    {
        margin-top: 20px;
        padding-top: 19px;
    }
    .actions
    {
        grid-template-columns: 1fr 1fr;
        margin-top: 20px;
        gap: 9px;
    }
    .tilt-button
    {
        grid-column: 1 / -1;
    }
    .keyboard-hint
    {
        display: none;
    }
    footer
    {
        flex-direction: column;
        padding: 20px 16px max(20px, env(safe-area-inset-bottom));
        gap: 8px;
        font-size: 9px;
    }
    footer a
    {
        margin: 0;
        min-height: 44px;
    }
    dialog
    {
        margin: auto 0 0;
        width: 100%;
        max-width: none;
        border-radius: 12px 12px 0 0;
        padding: 24px 24px max(24px, env(safe-area-inset-bottom));
    }
}
@media (prefers-reduced-motion: reduce)
{
    *, *::before, *::after
    {
        transition: none !important;
    }
}
