.sprite-tools{min-width:0;padding:24px}.sprite-tools fieldset{border:1px solid var(--border);border-radius:6px;min-width:0;margin:24px 0;padding:16px}.sprite-tools legend{padding:0 8px;font-weight:700}.sprite-tools fieldset:disabled{opacity:.7}.sprite-tools label{display:block}.sprite-tools input[type=number],.sprite-tools select{width:100%;min-width:0;margin:6px 0;display:block}.sprite-fields{grid-template-columns:repeat(auto-fit,minmax(140px,1fr));align-items:end;gap:12px;display:grid}.sprite-tools .sprite-check{align-items:center;gap:8px;margin:16px 0;display:flex}.sprite-tools input[type=checkbox]{flex:none;width:18px;height:18px}.sprite-tools .sprite-frame-list{grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:12px;max-height:400px;padding:4px;display:grid;overflow:auto}.sprite-frame{border:1px solid var(--border);border-radius:4px;padding:10px}.sprite-frame label{margin-bottom:10px;font-size:13px}.sprite-tools button{white-space:normal}.sprite-tools .preset-row{grid-template-columns:repeat(auto-fit,minmax(150px,1fr));display:grid}.sprite-tools select{min-height:44px;font:inherit;color:var(--foreground);border:1px solid var(--border);background:#fff;border-radius:4px;padding:10px}.sprite-tools figcaption{flex-wrap:wrap;justify-content:space-between;gap:8px;margin-bottom:8px;font-size:13px;display:flex}.sprite-tools button[aria-pressed=true]{outline:2px solid var(--accent);outline-offset:2px}.sprite-tools .preview-checker{height:240px;min-height:180px}.sprite-tools canvas{image-rendering:pixelated;object-fit:contain;width:auto;max-width:100%;height:auto;max-height:220px}.sprite-tools .preview-checker canvas{width:200px;height:200px}.sprite-tools .sprite-batch{padding:0;list-style:none}.sprite-batch li{border-bottom:1px solid var(--border);flex-wrap:wrap;align-items:center;gap:12px;padding:12px 0;display:flex}.sprite-batch span,.sprite-batch button{overflow-wrap:anywhere;max-width:100%}.sprite-swatches{grid-template-columns:repeat(8,1fr);gap:3px;max-width:400px;display:grid}.sprite-swatches span{text-align:center;border:1px solid #777;padding:6px}.sprite-tools textarea{width:100%;min-height:180px}.sprite-tools .code-heading{flex-wrap:wrap}@media (width<=420px){.sprite-tools{padding:12px}.sprite-tools fieldset{padding:10px}.sprite-fields{grid-template-columns:1fr}}.pixel-tool input[type=range]{width:100%;min-height:28px;margin:12px 0;display:block}.pixel-comparison{grid-template-columns:1fr 1fr;gap:16px;display:grid}.pixel-tool figure{min-width:0;margin:16px 0}.pixel-tool .pixel-comparison canvas{object-fit:contain;width:100%;height:auto;max-height:320px;image-rendering:pixelated}.pixel-tool .pixel-comparison figure:first-child canvas{image-rendering:auto}.pixel-tool .mask-stage{touch-action:none;-webkit-user-select:none;user-select:none;background:#eee;margin:16px 0;line-height:0;position:relative}.pixel-tool .mask-stage canvas{image-rendering:auto;width:100%;height:auto;max-height:none;display:block}.mask-region{cursor:move;touch-action:none;background:#ff000018;border:2px solid #f20;padding:0;position:absolute}.mask-region[aria-pressed=true]{background:#003fad18;border-color:#003fad}.mask-region .mask-handle{cursor:nwse-resize;background:#003fad;border:2px solid #fff;width:18px;height:18px;position:absolute;bottom:-3px;right:-3px}.pixel-tool .region-list{padding:0;list-style:none}.pixel-tool .region-row{border:1px solid var(--border);border-radius:4px;margin:14px 0;padding:12px}.pixel-tool .region-row .sprite-fields{grid-template-columns:repeat(4,minmax(0,1fr))}.pixel-tool .region-row input{padding:8px}@media (width<=600px){.pixel-comparison{grid-template-columns:1fr}.pixel-tool .region-row .sprite-fields{grid-template-columns:1fr 1fr}}.christmas-patterns-tool{flex-direction:column;gap:14px;display:flex}.christmas-patterns-tool .christmas-toolbar{flex-wrap:wrap;justify-content:space-between;align-items:flex-end;gap:12px;display:flex}.christmas-patterns-tool .christmas-gallery-heading{margin:0;font-size:20px;line-height:1.25}.christmas-patterns-tool .christmas-attribution{color:var(--muted,#475569);margin:4px 0 0;font-size:13px}.christmas-patterns-tool .christmas-filter-group{flex-wrap:wrap;gap:8px;display:flex}.christmas-patterns-tool .christmas-filter-group button{border:1px solid var(--border);width:auto;min-height:40px;color:var(--foreground);font:inherit;cursor:pointer;background:0 0;border-radius:6px;padding:6px 14px;font-size:14px;font-weight:600}.christmas-patterns-tool .christmas-filter-group button[aria-pressed=true]{background:var(--accent,#1d4ed8);border-color:var(--accent,#1d4ed8);color:#fff}.christmas-patterns-tool .christmas-status{border:1px solid var(--border);background:var(--surface,#f8fafc);color:var(--foreground);border-radius:6px;margin:0;padding:10px 12px;font-size:14px}.christmas-patterns-tool .christmas-pattern-grid{grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:16px;margin:0;padding:0;list-style:none;display:grid}.christmas-patterns-tool .christmas-pattern-card{border:1px solid var(--border);background:#fff;border-radius:10px;flex-direction:column;min-width:0;display:flex;overflow:hidden}.christmas-patterns-tool .christmas-preview-frame{background:#f8fafc;justify-content:center;align-items:center;padding:12px 12px 0;display:flex}.christmas-patterns-tool .christmas-preview-frame img{aspect-ratio:1;width:100%;max-width:220px;height:auto;display:block}.christmas-patterns-tool .christmas-card-body{flex-direction:column;flex:auto;gap:10px;padding:12px 14px 14px;display:flex}.christmas-patterns-tool .christmas-card-header{justify-content:space-between;align-items:flex-start;gap:8px;display:flex}.christmas-patterns-tool .christmas-card-header h3{margin:0;font-size:17px;line-height:1.25}.christmas-patterns-tool .christmas-badge{border-radius:999px;flex:none;padding:2px 8px;font-size:12px;font-weight:700;line-height:1.5;display:inline-block}.christmas-patterns-tool .christmas-badge-easy{color:#166534;background:#dcfce7}.christmas-patterns-tool .christmas-badge-medium{color:#92400e;background:#fef3c7}.christmas-patterns-tool .christmas-card-desc{color:var(--muted,#475569);margin:0;font-size:13px;line-height:1.45}.christmas-patterns-tool .christmas-card-meta{background:var(--surface,#f8fafc);border:1px solid var(--border);border-radius:6px;grid-template-columns:repeat(3,1fr);gap:6px;margin:0;padding:8px;display:grid}.christmas-patterns-tool .christmas-card-meta dt{color:var(--muted,#475569);margin:0;font-size:11px}.christmas-patterns-tool .christmas-card-meta dd{margin:2px 0 0;font-size:13px;font-weight:700}.christmas-patterns-tool .christmas-swatch-row{flex-wrap:wrap;align-items:center;gap:5px;display:flex}.christmas-patterns-tool .christmas-swatch-dot{border:1px solid #0f172a4d;border-radius:50%;width:14px;height:14px;display:inline-block}.christmas-patterns-tool .christmas-card-actions{flex-direction:column;gap:8px;margin-top:auto;padding-top:4px;display:flex}.christmas-patterns-tool .christmas-btn-primary,.christmas-patterns-tool .christmas-btn-secondary{width:100%;min-height:44px;font:inherit;text-align:center;cursor:pointer;box-sizing:border-box;border-radius:6px;justify-content:center;align-items:center;padding:8px 12px;font-size:14px;font-weight:600;text-decoration:none;display:inline-flex}.christmas-patterns-tool .christmas-btn-primary{background:var(--accent,#1d4ed8);color:#fff;border:1px solid var(--accent,#1d4ed8)}.christmas-patterns-tool .christmas-btn-primary:hover:not(:disabled){filter:brightness(.92)}.christmas-patterns-tool .christmas-btn-primary:disabled{opacity:.6;cursor:wait}.christmas-patterns-tool .christmas-btn-secondary{color:var(--foreground);border:1px solid var(--border);background:0 0}.christmas-patterns-tool .christmas-btn-secondary:hover{border-color:var(--accent,#1d4ed8);color:var(--accent,#1d4ed8)}.christmas-patterns-tool .christmas-footer-note{color:var(--muted,#475569);margin:4px 0 0;font-size:13px}@media (width<=360px){.christmas-patterns-tool .christmas-pattern-grid{grid-template-columns:1fr}}.lesson-page .tool-hero{gap:48px;min-height:auto;padding-top:56px;padding-bottom:56px}.lesson-page .hero-copy h1{letter-spacing:-1.5px;font-size:clamp(36px,4vw,54px)}.lesson-page .intro{max-width:620px}.sprite-lab-actions{gap:20px;display:grid}.sprite-lab-actions h2{margin:0}.lab-converter-link{background:var(--accent);color:#fff;border-radius:5px;padding:18px 20px;font-weight:600;text-decoration:none}.lab-converter-link:hover{color:#fff;filter:brightness(1.12)}.sprite-lab-actions button{text-align:left}.sprite-lab-actions>a:last-child{padding-block:8px}.sprite-packet{margin-top:64px;scroll-margin-top:24px}.packet-sheet{border:1px solid var(--border);overflow-wrap:anywhere;background:#fff;border-radius:8px;margin-block:28px;padding:28px}.packet-sheet>:first-child{margin-top:0}.packet-sheet .sprite-drawing-grid{width:min(100%,480px);height:auto;margin:24px auto;display:block}.packet-sheet table{border-collapse:collapse;table-layout:fixed;width:100%;margin-block:20px;font-size:13px;line-height:1.5}.packet-sheet td,.packet-sheet th{text-align:left;vertical-align:top;overflow-wrap:anywhere;border:1px solid #929c96;padding:10px 8px}.packet-sheet th{background:var(--soft)}.packet-sheet td:first-child{font-weight:600}.packet-footer{color:var(--muted);font-size:11px;margin-top:24px!important}.packet-checklist{padding:0;list-style:none}.packet-checklist li{padding-left:24px;position:relative}.packet-checklist li:before{content:"";border:1px solid;width:12px;height:12px;position:absolute;top:.55em;left:0}@media (width<=600px){.lesson-page .tool-hero{gap:24px;padding-top:36px}.packet-sheet{padding:18px 12px}.packet-sheet table{font-size:11px}.packet-sheet td,.packet-sheet th{padding:8px 5px}}@page{size:auto;margin:14mm}@media print{body:has(.sprite-packet){color:#000;background:#fff}.lesson-page .tool-hero,.lesson-page .faq,.lesson-page .related,.lesson-page .examples,.lesson-page .guide>:not(.sprite-packet){display:none!important}body:has(.sprite-packet) .site-header{display:none!important}body:has(.sprite-packet) .skip-link{display:none!important}body:has(.sprite-packet) footer{display:none!important}.lesson-page .lower-content,.lesson-page .guide{max-width:none;margin:0;padding:0}.sprite-packet{color:#000;margin:0;font-size:10pt;line-height:1.45}.packet-sheet{break-after:page;break-inside:avoid;border:0;border-radius:0;margin:0;padding:0}.packet-sheet:last-child{break-after:auto}.packet-sheet h2{margin:0 0 14pt;font-size:19pt}.packet-sheet h3{break-after:avoid;margin:14pt 0 8pt;font-size:13pt}.packet-sheet p{margin-bottom:10pt}.packet-sheet li{margin-block:6pt}.packet-sheet .sprite-drawing-grid{width:145mm;max-width:100%;height:145mm;margin:12pt auto}.packet-sheet table{font-size:9pt;line-height:1.35}.packet-sheet tr,.packet-sheet li,.sprite-drawing-grid{break-inside:avoid}.packet-sheet th{background:#fff}.packet-sheet td,.packet-sheet th{padding:6pt}.packet-footer{color:#000;font-size:8pt}.sprite-packet a{color:#000;text-decoration:none}}html:root{--background:#f6f5f0;--foreground:#232b27;--accent:#285a43;--soft:#eaf0e6}html .brand{white-space:normal;font-size:21px}html .site-header{max-width:1328px;min-height:86px}html .tool-hero{grid-template-columns:minmax(0,1fr);gap:28px;max-width:1328px;min-height:auto;padding-top:48px}html .hero-copy h1{letter-spacing:-1.8px;max-width:100%;margin-bottom:16px;font-size:clamp(34px,4vw,54px)}html .hero-copy .eyebrow{margin-bottom:14px}html .hero-copy .intro{max-width:780px;margin-bottom:8px;font-size:18px}html .hero-copy .quiet{margin:0}html .tool-card{border-radius:10px;padding:0;overflow:hidden;box-shadow:0 8px 24px #20332d06}.converter-top{border-bottom:1px solid var(--border);letter-spacing:1px;justify-content:space-between;gap:12px;padding:19px 24px;font-size:11px;font-weight:700;display:flex}.local-badge{color:var(--accent);letter-spacing:0;font-weight:400}.converter-layout{grid-template-columns:300px minmax(0,1fr);display:grid}.converter-controls{border-right:1px solid var(--border);background:#fcfcf9;padding:24px}.converter-workspace{min-width:0;padding:24px}.step-label{letter-spacing:1.4px;color:var(--muted);font-size:10px;font-weight:700;display:block}.upload-zone{cursor:pointer;background:var(--soft);border:1px dashed #93a695;border-radius:6px;padding:16px;display:block;position:relative}.upload-zone strong{margin:12px 0 8px;font-size:15px;display:block}.upload-zone>span:nth-of-type(2){color:var(--muted);font-size:11px;font-weight:400}.upload-zone .visually-hidden-input{clip:rect(0 0 0 0);white-space:nowrap;border:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.upload-zone:focus-within{outline:2px solid var(--foreground);outline-offset:2px}.upload-zone .upload-button{border:1px solid var(--border);color:var(--foreground);background:#fff;border-radius:3px;margin-top:14px;padding:7px 12px;font-size:12px;font-weight:600;display:inline-block}.file-name{overflow-wrap:anywhere;color:var(--muted);margin:8px 0 14px;font-size:11px}html .tool-card .secondary{border:1px solid var(--border);color:var(--foreground);background:#fff;min-height:42px;padding:10px 12px;font-size:13px}html .tool-card .secondary[aria-pressed=true]{border-color:var(--accent);background:var(--soft);color:var(--accent)}html .tool-card button:disabled{opacity:.55;cursor:default}.arcade-converter fieldset{border:0;min-width:0;margin:24px 0 0;padding:0}.arcade-converter legend{margin-bottom:12px}.preset-row{gap:10px;margin-bottom:14px;display:flex}.preset-row button{justify-content:center}.dimension-row{grid-template-columns:minmax(0,1fr) 10px minmax(0,1fr);align-items:center;gap:10px;display:grid}.dimension-row label{margin-bottom:7px;font-size:12px}.dimension-row input[type=number]{height:44px;margin-bottom:16px;padding:8px 10px;font-size:16px}.arcade-converter select{border:1px solid var(--border);width:100%;color:var(--foreground);min-height:44px;font:inherit;background:#fff;border-radius:4px;padding:10px 6px;font-size:12px}.arcade-converter label{font-size:12px}.checkbox-label{align-items:center;gap:8px;min-height:30px;display:flex}.checkbox-label input{width:18px;height:18px;accent-color:var(--accent)}.arcade-converter input[type=range]{width:100%;accent-color:var(--accent);min-height:28px}.arcade-converter input[type=color]{border:1px solid var(--border);background:#fff;width:100%;height:38px;padding:2px}.control-help{color:var(--muted);margin:8px 0 16px;font-size:11px;line-height:1.6}.converter-controls>button[type=submit]{margin-top:20px}.preview-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;display:grid}.preview-grid figure{min-width:0;margin:0}.preview-grid figcaption{flex-wrap:wrap;justify-content:space-between;gap:6px;margin-bottom:10px;font-size:13px;font-weight:600;display:flex}.preview-grid figcaption span{color:var(--muted);font-size:11px;font-weight:400}.preview-checker,.transparent-swatch{background-color:#fff;background-image:conic-gradient(#e2e6df 25%, transparent 0 50%, #e2e6df 0 75%, transparent 0);background-size:16px 16px}.preview-checker{aspect-ratio:1;border:1px solid var(--border);border-radius:5px;place-items:center;padding:12px;display:grid;overflow:hidden}.preview-checker canvas{object-fit:contain;width:100%;height:100%;min-height:0;image-rendering:pixelated;display:block}.preview-checker p{color:#4e5c51;text-align:center;background:#fffffff0;border-radius:3px;padding:10px;font-size:12px}.palette-heading{letter-spacing:1px;color:var(--muted);flex-wrap:wrap;justify-content:space-between;gap:6px;margin:24px 0 12px;font-size:10px;display:flex}.palette-heading span:last-child{letter-spacing:0}.palette-swatches{grid-template-columns:repeat(16,minmax(0,1fr));gap:4px;display:grid}.palette-swatches span{aspect-ratio:1;border:1px solid #0002;border-radius:3px;width:100%;display:block}.palette-swatches small{text-align:center;color:var(--muted);margin-top:6px;font:10px monospace;display:block}.code-heading{justify-content:space-between;align-items:center;gap:12px;margin:24px 0 10px;display:flex}.code-heading label{margin:0;font-size:13px}html .tool-card .copy-button{gap:16px;width:auto;min-width:116px}.arcade-converter textarea{border:1px solid var(--border);color:#234330;resize:vertical;white-space:pre;background:#f7f8f5;border-radius:5px;width:100%;height:164px;padding:14px;font:11px/1.5 monospace}.converter-status{min-height:32px;color:var(--accent);margin:10px 0 0;font-size:12px;line-height:1.6}.converter-error{color:#9d2e15;font-size:13px;line-height:1.6}.arcade-converter noscript{padding:16px;display:block}@media (width<=800px){html .site-header{gap:12px;min-height:74px;padding:18px 20px}html .brand{max-width:235px;font-size:18px}html .tool-hero{gap:24px;padding:30px 16px 40px}html .hero-copy h1{letter-spacing:-1.3px;font-size:36px}html .hero-copy .intro{font-size:16px}.converter-layout{grid-template-columns:minmax(0,1fr)}.converter-controls{border-right:0;border-bottom:1px solid var(--border);padding:18px}.converter-workspace{padding:18px}.converter-top{padding:16px 18px;font-size:10px}.preview-grid{gap:10px}.preview-grid figcaption{font-size:12px}.preview-grid figcaption span{font-size:10px}.preview-checker{padding:4px}.preview-checker p{padding:6px;font-size:10px}.palette-swatches{grid-template-columns:repeat(8,minmax(0,1fr));gap:7px}.palette-swatches span{aspect-ratio:1.6}}.palette-layout{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:24px;padding:24px;display:grid}.palette-layout .converter-workspace{padding:0}.editable-palette{grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:24px;display:grid}.editable-palette label{gap:6px;min-width:0;display:grid}.editable-palette small{font:11px monospace}.locked-color{border:1px solid var(--border);color:#232b27;place-items:center;height:38px;display:grid}.palette-fields{min-width:0}.arcade-converter .palette-fields{margin-top:0}.frame-list{max-height:230px;margin:16px 0;overflow:auto}.frame-list>div{justify-content:space-between;align-items:center;gap:8px;margin:8px 0;display:flex}.frame-list label{align-items:center;gap:8px;display:flex}.frame-list input{width:18px;height:18px}html .frame-list button{width:auto}.arcade-converter details{margin-top:20px}.arcade-converter details summary{cursor:pointer;margin-bottom:16px}.palette-layout .upload-zone{margin-bottom:12px}.palette-layout .preview-grid{margin-top:18px}@media (width<=800px){.palette-layout{grid-template-columns:minmax(0,1fr);padding:18px}.editable-palette{gap:10px}.editable-palette label span{font-size:10px}.palette-layout .converter-workspace{padding:0}}.gradient-track{border:1px solid var(--border);border-radius:4px;height:36px;margin:28px 22px 38px;position:relative}.gradient-tool .gradient-thumb{touch-action:none;border:3px solid #fff;border-radius:50%;width:36px;min-width:0;height:36px;min-height:0;padding:0;position:absolute;top:23px;transform:translate(-50%);box-shadow:0 0 0 1px #333}.gradient-stops{grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:16px;display:grid}.gradient-stop{border:1px solid var(--border);border-radius:4px;min-width:0;padding:12px}.gradient-stop input{width:100%;max-width:100%;min-height:44px;margin:4px 0 10px}.gradient-tool input[type=range]{width:100%;min-height:44px;display:block}.gradient-tool .preview-checker canvas{width:100%;max-width:100%;height:220px}.gradient-tool .gradient-stop button{width:100%}.image-palette-tool fieldset{border:1px solid var(--border);min-width:0;margin:16px 0;padding:12px}.palette-image canvas{object-fit:fill;cursor:crosshair;width:100%;max-width:100%;height:auto;max-height:none;image-rendering:pixelated;display:block}.image-palette-swatches{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;display:grid}.palette-swatch{flex-direction:column;gap:8px;min-width:0;display:flex}.palette-chip{border:1px solid var(--border);height:48px;display:block}.palette-swatch span{font-size:12px}.palette-shares{padding:0;font-size:13px;list-style:none}.palette-shares li{align-items:center;gap:8px;margin:8px 0;display:flex}.palette-dot{border:1px solid var(--border);flex-shrink:0;width:20px;height:20px;display:inline-block}.image-palette-tool .palette-snap{align-items:center;gap:8px;margin-top:16px;display:flex}.image-palette-tool .palette-snap input{width:auto}.image-palette-tool textarea{width:100%;min-height:80px}.image-palette-tool input[type=text]{border:1px solid var(--border);width:100%;min-width:0;font:inherit;border-radius:4px;margin:6px 0;padding:10px;display:block}.image-palette-tool .sprite-actions{grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:8px;display:grid}@media (width<=420px){.image-palette-swatches{grid-template-columns:1fr}}.pixel-tools-index{padding:20px}.pixel-tools-index section+section{margin-top:28px}.pixel-tools-cards{grid-template-columns:repeat(auto-fit,minmax(min(100%,230px),1fr));gap:12px;display:grid}.pixel-tool-link{border:1px solid var(--border);color:inherit;border-radius:6px;padding:16px;text-decoration:none;display:block}.pixel-tool-link:hover,.pixel-tool-link:focus-visible{border-color:var(--accent);background:var(--soft)}.pixel-tool-link h3{margin-top:0;font-size:18px}.pixel-tool-link p{margin-bottom:0;font-size:14px}.perler-tool .perler-upload-row{flex-wrap:wrap;align-items:flex-start;gap:12px;display:flex}.perler-tool .perler-sample-btn{min-height:44px;color:var(--foreground);border:1px solid var(--border);font:inherit;cursor:pointer;background:0 0;border-radius:4px;padding:10px 14px}.perler-tool .perler-sample-btn:hover:not(:disabled){border-color:var(--accent)}.perler-tool .perler-library-link{align-items:center;text-decoration:none;display:inline-flex}.perler-tool .perler-swap-panel{border:1px solid var(--border);background:var(--surface,#fafafa);border-radius:6px;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));align-items:end;gap:10px;margin-top:10px;padding:12px;display:grid}.perler-tool .perler-swap-actions{flex-wrap:wrap;gap:8px;display:flex}.perler-tool .perler-swap-actions button{width:auto;min-height:40px}.perler-tool .perler-preset-row{grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:8px;margin-bottom:12px;display:grid}.perler-tool .perler-summary-grid{grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:10px;margin:16px 0;display:grid}.perler-tool .perler-stat{border:1px solid var(--border);background:var(--surface,#fafafa);border-radius:6px;padding:10px 12px}.perler-tool .perler-stat-label{color:var(--muted,#475569);font-size:12px;display:block}.perler-tool .perler-stat-value{margin-top:2px;font-size:18px;font-weight:700;display:block}.perler-tool .perler-preview-toolbar{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:10px;margin:16px 0 8px;display:flex}.perler-tool .perler-view-tabs{flex-wrap:wrap;gap:8px;display:flex}.perler-tool .perler-view-tabs button{width:auto;min-height:38px;padding:6px 12px}.perler-tool .perler-preview-grid{grid-template-columns:1fr 1fr;gap:16px;margin:12px 0;display:grid}.perler-tool .perler-preview-grid[data-single=true]{grid-template-columns:1fr}.perler-tool .perler-stage{border:1px solid var(--border);background:#fff;border-radius:6px;min-width:0;padding:12px}.perler-tool .perler-stage canvas{object-fit:contain;image-rendering:auto;width:100%;height:auto;max-height:460px;display:block}.perler-tool .perler-stage-empty{text-align:center;min-height:200px;color:var(--muted,#475569);justify-content:center;align-items:center;padding:16px;display:flex}.perler-tool .perler-export-row{grid-template-columns:repeat(auto-fit,minmax(175px,1fr));gap:10px;display:grid}.perler-tool .perler-bead-list-wrap{border:1px solid var(--border);border-radius:6px;max-height:440px;margin-top:16px;overflow:auto}.perler-tool .perler-bead-table{border-collapse:collapse;width:100%;font-size:14px}.perler-tool .perler-bead-table th,.perler-tool .perler-bead-table td{text-align:left;border-bottom:1px solid var(--border);white-space:nowrap;padding:8px 10px}.perler-tool .perler-bead-table th{z-index:1;background:var(--surface,#f8fafc);font-weight:700;position:sticky;top:0}.perler-tool .perler-bead-table tr.is-highlighted{background:#2563eb1a}.perler-tool .perler-swatch-btn{width:auto;min-height:0;font:inherit;color:inherit;cursor:pointer;background:0 0;border:1px solid #0000;border-radius:4px;justify-content:flex-start;align-items:center;gap:8px;padding:2px 6px;display:inline-flex}.perler-tool .perler-swatch-btn[aria-pressed=true]{border-color:var(--accent);font-weight:700}.perler-tool .perler-swatch-chip{border:1px solid #0f172a59;border-radius:50%;flex:none;width:18px;height:18px;display:inline-block}.perler-tool .perler-highlight-bar{border:1px solid var(--accent);background:#2563eb0f;border-radius:6px;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px;margin-top:8px;padding:8px 12px;font-size:13px;display:flex}.perler-tool .perler-disclaimer{color:var(--muted,#475569);margin-top:16px;font-size:13px}.perler-tool .perler-copy-fallback{margin-top:10px}@media (width<=720px){.perler-tool .perler-preview-grid{grid-template-columns:1fr}}@media (width<=420px){.perler-tool .perler-bead-table th,.perler-tool .perler-bead-table td{padding:6px;font-size:12px}}.sheet-drop{border:2px dashed var(--border);border-radius:6px;padding:16px}.sheet-workbench .sheet-frames{grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px;max-height:540px;padding:4px;list-style:none;display:grid;overflow:auto}.sheet-frames li{border:1px solid var(--border);overflow-wrap:anywhere;border-radius:4px;flex-direction:column;gap:10px;min-width:0;padding:12px;display:flex}.sheet-frames li>canvas{object-fit:contain;background:#e6e6e6;align-self:start;width:auto;max-width:100%;height:80px}.sheet-workbench .sheet-handle{touch-action:none;cursor:grab}.sheet-workbench figure{margin:20px 0}.sheet-workbench figure canvas{object-fit:contain;border:1px solid var(--border);background:repeating-conic-gradient(#eee 0% 25%,#fff 0% 50%) 0 0/16px 16px;width:min(100%,480px);height:260px;max-height:260px}.sheet-workbench summary{cursor:pointer;padding:16px 0}.sheet-workbench .sheet-frames .sprite-check{margin:0}@media (width<=420px){.sheet-workbench .sheet-frames{grid-template-columns:1fr}.sheet-workbench .sheet-frames li{grid-template-columns:minmax(0,1fr) 68px;align-items:center;display:grid}.sheet-frames .sheet-handle{grid-area:1/2;padding:8px}.sheet-frames .sprite-check{grid-area:1/1}.sheet-frames li>canvas{grid-area:2/1;height:40px}.sheet-frames li>span{grid-area:3/1}.sheet-frames li>button[aria-pressed]{grid-area:2/2/4;padding:8px}.sheet-workbench .sheet-frames .preset-row{grid-column:1/-1;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}.sheet-frames .preset-row button{padding:10px 4px}}.encoding-layout{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:40px;padding:24px;display:grid}.encoding-layout section{min-width:0}.encoding-layout h2{margin:0 0 20px;font-size:20px}.encoding-layout label{margin:16px 0 8px;font-size:13px;font-weight:600;display:block}.encoding-layout select{border:1px solid var(--border);width:100%;color:var(--foreground);font:inherit;background:#fff;border-radius:4px;padding:10px;font-size:14px}.encoding-grid{grid-template-columns:repeat(8,minmax(0,1fr));gap:3px;max-width:384px;display:grid}html .tool-card .encoding-grid button{aspect-ratio:1;border:1px solid #69756c;border-radius:2px;place-items:center;width:100%;min-width:0;min-height:0;padding:0;font:700 16px monospace;display:grid}.encoding-grid button[aria-pressed=true]{outline-offset:1px;z-index:1;outline:3px solid #285a43}.encoding-grid button:focus-visible{outline-offset:2px;outline:3px solid #003fad}.pixel-inspector{min-height:56px;font-size:14px;line-height:1.8}.encoding-layout textarea{border:1px solid var(--border);white-space:pre;resize:vertical;color:#234330;background:#f7f8f5;border-radius:4px;width:100%;min-height:180px;padding:12px;font:13px/1.6 monospace;display:block}.encoding-layout textarea[aria-invalid=true]{border-color:#9d2e15}.encoding-layout button{margin-top:10px}.encoding-grid button{margin-top:0}.encoding-print-actions{border-top:1px solid var(--border);flex-wrap:wrap;align-items:center;gap:16px;padding:20px 24px;display:flex}html .tool-card .encoding-print-actions button{width:auto}.image-encoding noscript{padding:20px;display:block}.encoding-packet{border:1px solid var(--border);background:#fff;border-radius:8px;margin:40px 0;padding:28px;scroll-margin-top:24px}.encoding-packet pre{white-space:pre-wrap;font-size:14px;line-height:1.8}.encoding-packet li{margin-bottom:18px}.encoding-packet .response-space{border-bottom:1px solid #87958a;height:34px;display:block}@media (width<=800px){.encoding-layout{grid-template-columns:minmax(0,1fr);gap:28px;padding:18px}.encoding-layout textarea{font-size:12px}.encoding-packet{padding:18px}}@media print{body:has(.encoding-packet){color:#000;background:#fff}html:not([data-encoding-print=teacher]) .encoding-teacher,html[data-encoding-print=teacher] .encoding-student{display:none!important}body:has(.encoding-packet) .site-header{display:none!important}body:has(.encoding-packet) .skip-link{display:none!important}body:has(.encoding-packet) footer{display:none!important}body:has(.encoding-packet) .tool-hero{display:none!important}body:has(.encoding-packet) .faq{display:none!important}body:has(.encoding-packet) .related{display:none!important}body:has(.encoding-packet) .guide>:not(.encoding-packet){display:none!important}:is(body:has(.encoding-packet) .lower-content,body:has(.encoding-packet) .guide){max-width:none;margin:0;padding:0}.encoding-packet{color:#000;border:0;margin:0;padding:0;font-size:10pt;line-height:1.45}.encoding-packet h2{margin:0 0 12pt;font-size:18pt}.encoding-packet h3{margin:12pt 0 8pt;font-size:12pt}.encoding-packet pre{color:#000;background:#fff;font-size:10pt;line-height:1.5}.encoding-packet li{break-inside:avoid;margin-bottom:12pt}.encoding-packet .response-space{height:24pt}}
