:root { font-family: 'Malgun Gothic', 'Apple SD Gothic Neo', system-ui, sans-serif; color: #263f3a; background: #f5f1e7; line-height: 1.55; color-scheme: light; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
button { font: inherit; cursor: pointer; }
button:focus-visible, select:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid #a34128; outline-offset: 4px; }
button:disabled { opacity: .55; cursor: not-allowed; }
h1, h2, p { margin-top: 0; }
.workshop { max-width: 1160px; margin: auto; padding: 22px clamp(16px, 4vw, 44px) 30px; }
.header { display: flex; align-items: center; gap: 13px; padding-bottom: 16px; border-bottom: 1px solid #d6d6c8; }
.brand { flex: none; width: 44px; color: #376758; }
.eyebrow { margin: 0; color: #3c6657; font-size: .82rem; font-weight: 700; }
h1 { margin: 0; font-size: clamp(1.3rem, 2.8vw, 1.7rem); line-height: 1.25; }
.back-link { margin-left: auto; min-height: 48px; display: flex; align-items: center; color: #24473b; font-weight: 700; }
.pause-button { min-height: 48px; padding: 9px 16px; background: #fffefa; border: 1px solid #79998b; border-radius: 9px; color: #24473b; font-weight: 700; white-space: nowrap; }
.back-link[hidden] + .pause-button { margin-left: auto; }
.intro { display: flex; justify-content: space-between; align-items: end; gap: 20px; padding: 29px 0 22px; }
.intro h2 { margin-bottom: 6px; font-size: clamp(1.6rem, 3.5vw, 2.25rem); letter-spacing: -.04em; }
.intro p { margin: 0; color: #465e52; }
.progress { padding: 7px 13px; border-radius: 999px; background: #fffdf7; border: 1px solid #d7dbd0; color: #315b4d; font-weight: 700; white-space: nowrap; }
.layout { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(280px, .7fr); gap: 18px; align-items: stretch; }
.work-card, .guide, .help { border: 1px solid #d7dbcf; background: #fffef9; border-radius: 15px; }
.work-card { padding: clamp(18px, 3vw, 27px); background: #e8eee6; min-width: 0; }
.work-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.work-heading h2, .guide h2 { margin: 3px 0 0; font-size: 1.2rem; }
.badge { padding: 5px 11px; border-radius: 999px; background: #fffdf7; border: 1px solid #cbd9cb; font-size: .9rem; font-weight: 700; white-space: nowrap; }
.instructions { margin: 12px 0 0; color: #425c4f; font-size: .95rem; }
.board-area { padding: 27px 8px; }
.plate { position: relative; max-width: 490px; height: clamp(270px, 47vw, 340px); margin: auto; border: 3px solid #ad825a; border-radius: 25px; background: #e8cba5; box-shadow: 0 11px 0 #caa77c, 0 17px 25px #566d5d30; transform: perspective(900px) rotateX(var(--tilt-x, 0deg)) rotateZ(var(--tilt-z, 0deg)); transition: transform .55s ease; }
.plate-art { position: absolute; inset: 10px; display: grid; place-items: center; color: #916746; pointer-events: none; }
.plate-art svg { width: 100%; height: 100%; }
.plate-center { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); text-align: center; color: #725638; font-size: .83rem; line-height: 1.5; pointer-events: none; }
.corner { position: absolute; z-index: 1; width: clamp(90px, 25%, 120px); min-height: 104px; padding: 8px 4px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: #294b3f; border: 1px solid #997350; border-radius: 12px; background: #fffaf0; box-shadow: 0 3px 0 #b79975; }
.corner:hover { background: #f5fff5; border-color: #316c54; }
.corner.finished { background: #e2f1e2; border-color: #437b5b; }
.corner.nw { top: 12px; left: 12px; }.corner.ne { top: 12px; right: 12px; }.corner.sw { bottom: 12px; left: 12px; }.corner.se { bottom: 12px; right: 12px; }
.screw { position: relative; display: block; width: 32px; height: 32px; border: 3px solid #6a6f62; border-radius: 50%; background: #d8ddd0; transform: rotate(var(--turn, 0deg)); transition: transform .55s cubic-bezier(.2,.65,.25,1); }
.screw::before, .screw::after { content: ''; position: absolute; top: 11px; left: 4px; width: 18px; height: 3px; border-radius: 2px; background: #62685e; }
.screw::after { transform: rotate(90deg); }
.screw span { position: absolute; top: 3px; left: 5px; width: 4px; height: 4px; border-radius: 50%; background: #8b5537; }
.corner-name { font-weight: 700; font-size: .83rem; }
.corner-level { font-size: .82rem; color: #385c49; }
.status, .pause-note { display: flex; align-items: center; min-height: 60px; margin: 0; padding: 13px 15px; border-radius: 8px; color: #214c3e; background: #fffefa; font-weight: 700; }
.tilt { margin: 0 0 10px; color: #31584a; font-weight: 700; text-align: center; }
.pause-note { margin-bottom: 8px; background: #fdf3df; color: #64431e; }
.guide { padding: 25px; }
.difficulty { display: grid; gap: 6px; margin-top: 18px; font-weight: 700; }
.difficulty select { min-height: 48px; width: 100%; padding: 8px; font: inherit; color: #294c3e; background: white; border: 1px solid #8ca698; border-radius: 8px; }
.steps { list-style: none; padding: 0; margin: 25px 0; }
.steps li { display: flex; align-items: start; gap: 12px; margin-bottom: 19px; }
.step-count { display: grid; place-items: center; flex: none; width: 31px; height: 31px; border-radius: 50%; background: #e6efe4; color: #2d5d45; font-weight: 700; }
.steps strong { display: block; }
.steps p { margin: 3px 0 0; font-size: .93rem; color: #4c6055; }
.tools { display: flex; flex-wrap: wrap; gap: 8px; border-top: 1px solid #e0e4db; padding-top: 21px; }
.secondary { min-height: 48px; padding: 9px 12px; border: 1px solid #8ca698; border-radius: 8px; background: white; color: #294c3e; font-weight: 700; }
.confirm { margin-top: 12px; padding: 12px; background: #fdf3df; border: 1px solid #dcc39a; border-radius: 8px; }
.confirm p { margin: 0 0 10px; color: #64431e; font-weight: 700; }
.confirm-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.guide-note { margin: 13px 0 0; color: #4d6357; font-size: .86rem; }
.help { margin-top: 18px; padding: 16px 22px; }
.help summary { min-height: 42px; display: flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 700; }
.help summary::before { content: '+'; display: grid; place-items: center; width: 27px; height: 27px; border-radius: 50%; background: #e8eee6; }
.help[open] summary::before { content: '−'; }
.help div { max-width: 72ch; color: #40584a; }
footer { padding-top: 24px; text-align: center; color: #4f655a; font-size: .86rem; }
.no-script { padding: 1rem; text-align: center; }
@media (max-width: 760px) { .layout { grid-template-columns: 1fr; } .intro { align-items: start; flex-direction: column; gap: 12px; } .steps { margin: 18px 0; } }
@media (max-width: 480px) { .header { flex-wrap: wrap; } .back-link { margin-left: 0; } }
@media (max-width: 360px) { .workshop { padding-left: 12px; padding-right: 12px; } .plate-center { display: none; } .corner { width: 80px; } .header { gap: 8px; } .pause-button { padding: 8px 10px; } }
@media (prefers-reduced-motion: reduce) { .screw, .plate { transition: none; } }

.practice { margin-top: 18px; }
.practice summary { min-height: 48px; display: flex; align-items: center; font-weight: 700; cursor: pointer; }
.practice .difficulty { margin-top: 4px; }
#ladder-host { max-width: 100%; }
