:root{color:#18362c;font-synthesis:none;--muted:#617168;--border:#d8ddd4;background:#f6f3eb;font-family:system-ui,sans-serif;line-height:1.5}*{box-sizing:border-box}body{margin:0}main{max-width:1120px;margin:auto;padding:40px 32px 28px}.brand{align-items:center;gap:14px;margin-bottom:32px;display:flex}.brand-logo{border-radius:10px;flex-shrink:0}.availability{background:#9aaba0;border-radius:50%;flex:0 0 10px;width:10px;height:10px;box-shadow:0 0 0 3px #18362c0a}.availability.available{background:#2e874b}.availability.unavailable{background:#c93c35}h1{letter-spacing:-.035em;margin:0;font-size:clamp(1.25rem,3vw,1.8rem);font-weight:600;line-height:1.25}h2{margin:0;font-size:1rem;font-weight:600}p{margin:12px 0}button,.analysis-link{color:#fff;min-height:44px;font:inherit;cursor:pointer;background:#18362c;border:1px solid #0000;border-radius:8px;justify-content:center;align-items:center;gap:8px;padding:10px 16px;font-weight:500;text-decoration:none;transition:background-color .12s;display:inline-flex}button:hover:not(:disabled),.analysis-link:hover{background:#2c5142}button:disabled{opacity:.5;cursor:default}:focus-visible{outline-offset:3px;outline:3px solid #a77722}.secondary{border-color:var(--border);color:#18362c;background:#fffdf8}.secondary:hover:not(:disabled){background:#e8ece3}.workspace{grid-template-columns:minmax(0,520px);justify-content:center;gap:32px;display:grid}.workspace.with-position{grid-template-columns:repeat(2,minmax(0,1fr))}.photo-panel,.position-panel{min-width:0}.panel-heading{justify-content:space-between;align-items:center;min-height:44px;margin-bottom:12px;display:flex}.photo-frame{aspect-ratio:1;background:#eeeee5;border:1px dashed #b8c2b6;border-radius:10px;place-items:center;width:100%;display:grid;overflow:hidden}.photo-frame.has-photo{border-style:solid;border-color:var(--border)}.workspace:not(.with-position) .photo-frame{aspect-ratio:4/3}.photo-placeholder{text-align:center;padding:24px}.photo-placeholder>svg{width:36px;height:36px;color:var(--muted)}.photo-placeholder p{margin:12px 0 4px;font-size:1.1rem}.photo-preview{object-fit:contain;width:100%;height:100%;min-height:0;display:block}.photo-actions{gap:12px;margin-top:16px;display:flex}.photo-actions button{flex:1}.hint{color:var(--muted);font-size:.8rem;line-height:1.6}.photo-terms{margin:18px 0 12px}.recognize-button,.analysis-link{width:100%}.recognition-status p{margin-bottom:0}.board{border-radius:4px;grid-template-columns:repeat(8,minmax(0,1fr));width:100%;display:grid;overflow:hidden;box-shadow:0 2px 8px #18362c14}.board button{aspect-ratio:1;border:0;border-radius:0;place-items:center;min-height:0;padding:0;display:grid;position:relative}.board button img{width:100%;height:100%;display:block}.board button:hover,.board button[aria-pressed=true]{box-shadow:inset 0 0 0 3px #547d42}.board button:focus-visible{outline-offset:-3px;z-index:1}.coordinate{pointer-events:none;font-size:clamp(.55rem,1.3vw,.75rem);font-weight:700;line-height:1;position:absolute}.rank{top:3px;left:3px}.file{bottom:2px;right:3px}.edit-hint{margin:8px 0 12px}.piece-editor,.board-controls{flex-wrap:wrap;align-items:center;gap:10px;font-size:.875rem;display:flex}.piece-editor{margin:12px 0}.board-controls{margin-bottom:16px}.flip-button{margin-left:auto}.flip-button[aria-pressed=true]{background:#e1e8dd;border-color:#819b74}input,select,textarea{font:inherit;max-width:100%}select{border:1px solid var(--border);color:#18362c;background:#fffdf8;border-radius:8px;min-height:44px;padding:8px 10px}textarea{resize:vertical;border:1px solid var(--border);color:#18362c;background:#fffdf8;border-radius:8px;width:100%;min-height:76px;margin:12px 0 8px;padding:12px;font-family:monospace;font-size:.85rem}.fen-details{margin-top:16px;font-size:.85rem}summary{cursor:pointer;width:fit-content}a{color:inherit;text-underline-offset:3px}[role=alert]{color:#922c21;font-size:.85rem}.feedback{align-items:center;gap:10px;display:flex;position:relative}.feedback-buttons{gap:4px;display:flex}.feedback-label{font-size:.875rem;font-weight:500}.feedback-thumb{font-family:Apple Color Emoji,Segoe UI Emoji,Noto Color Emoji,sans-serif;font-size:1.5rem;line-height:1}.feedback button{width:44px;color:var(--muted);border-color:var(--border);background:#fffdf8;padding:8px}.feedback button:hover:not(:disabled){background:#e8ece3}.feedback button[aria-pressed=true]{color:#fff;opacity:1;background:#18362c;border-color:#18362c}.feedback [role=alert]{z-index:2;background:#fffdf8;border:1px solid #dcb5ad;border-radius:8px;width:240px;margin:6px 0 0;padding:12px;position:absolute;top:100%;right:0;box-shadow:0 3px 12px #18362c14}footer{border-top:1px solid var(--border);color:var(--muted);margin-top:40px;padding-top:20px;font-size:.75rem}.footer-links{flex-wrap:wrap;gap:12px 24px;display:flex}.photo-references{margin-top:20px}.reference-row{flex-wrap:wrap;align-items:center;gap:8px 12px;margin-bottom:8px;display:flex}.photo-references h2{font-size:inherit}.photo-references code{overflow-wrap:anywhere}.photo-references button{min-height:36px;color:inherit;border-color:var(--border);background:0 0;padding:6px 10px;font-size:.75rem}.photo-references button:hover{background:#e8ece3}.photo-references details{max-width:600px}.terms{max-width:780px}.terms h1{margin:24px 0;font-size:clamp(2rem,5vw,3rem)}.terms p{line-height:1.7}.terms h2{margin-top:32px}.sr-only{clip-path:inset(50%);white-space:nowrap;border:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}@media (width<=720px){main{padding:24px 16px}.brand{gap:12px;margin-bottom:24px}.workspace.with-position{grid-template-columns:minmax(0,520px);gap:24px}.with-position .photo-frame{aspect-ratio:4/3}.coordinate{font-size:.65rem}.photo-actions{gap:8px}.photo-actions button{padding-inline:10px}.board-controls{gap:8px}.board-controls button{padding-inline:10px}}@media (prefers-reduced-motion:reduce){button,.analysis-link{transition:none}}
