:root{--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light;color:#172239;--ink:#172239;--muted:#4e5c71;--blue:#204dbc;--line:#d9e0eb;background:#f4f6fb;font:16px/1.5 Segoe UI,-apple-system,BlinkMacSystemFont,sans-serif}*{box-sizing:border-box}[hidden]{display:none!important}body{margin:0}main{width:min(100% - 32px,1060px);margin:0 auto;padding:40px 0 56px}h1,h2,h3,p{margin:0}h1{letter-spacing:-.045em;font-size:clamp(1.7rem,4vw,2.8rem);line-height:1.08}.page-header{justify-content:space-between;align-items:flex-start;gap:12px;margin-bottom:24px;display:flex}.page-header p{color:var(--muted);margin-top:8px}.lang-switch{border:1px solid var(--line);background:#eef2f8;border-radius:9px;flex:none;gap:3px;padding:3px;display:flex}.lang-switch button{background:0 0;border-color:#0000;min-height:32px;padding:4px 10px;font-size:.875rem;font-weight:650}.lang-switch button[aria-pressed=true]{color:#153f9f;background:#fff;border-color:#b8caf7}.small-break{display:none}.workspace{grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);align-items:start;gap:20px;display:grid}.image-panel,.recognition-panel,.debug{border:1px solid var(--line);background:#fff;border-radius:16px;padding:18px}.stage{isolation:isolate;background:#101a2b;border-radius:11px;height:clamp(230px,46vw,440px);position:relative;overflow:hidden}.preview,.preview img,#live-video,.empty{width:100%;height:100%;position:absolute;inset:0}.preview img,#live-video{object-fit:contain}.empty{color:#e0eafa;text-align:center;place-content:center;justify-items:center;gap:19px;padding:10px;display:grid}.focus-mark{border:2px dashed #89aef1;border-radius:8px;width:50px;height:43px;display:block}.guide{pointer-events:none;border:1px solid #cbddff;position:absolute;box-shadow:0 0 0 1px #24334d70}.guide.active{box-shadow:0 0 0 100vmax #08122372}.guide i{border:0 solid #d9e8ff;width:17px;height:17px;position:absolute}.guide i:first-child{border-top-width:3px;border-left-width:3px;top:-1px;left:-1px}.guide i:nth-child(2){border-top-width:3px;border-right-width:3px;top:-1px;right:-1px}.guide i:nth-child(3){border-bottom-width:3px;border-left-width:3px;bottom:-1px;left:-1px}.guide i:nth-child(4){border-bottom-width:3px;border-right-width:3px;bottom:-1px;right:-1px}.source-mode{margin-top:12px}.image-actions{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:12px;display:grid}#camera-status{margin-top:6px}button,.file-button,.mode-switch label{font:inherit;color:var(--ink);cursor:pointer;text-align:center;border:1px solid var(--line);background:#fff;border-radius:8px;min-height:44px;padding:8px 11px;font-weight:600}button:hover:not(:disabled),.file-button:hover{background:#edf3ff}button[disabled]{opacity:.55;cursor:default}.file-button:has(:disabled){opacity:.55;cursor:default}.file-button,.mode-switch label{place-items:center;display:grid;position:relative}.file-button input,.mode-switch input{opacity:0;width:100%;height:100%;cursor:inherit;margin:0;position:absolute;inset:0}button:focus-visible,label:focus-within,summary:focus-visible{outline-offset:2px;outline:3px solid #4879ee}.privacy,.mode-help,.model-state,.run-status,#unscored,#confirmation,#score-note{color:var(--muted);font-size:.875rem}.privacy{margin-top:8px}fieldset{border:0;min-inline-size:0;margin:0;padding:0}legend{margin-bottom:7px;padding:0;font-weight:650}.mode-switch{background:#eef2f8;border-radius:11px;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;padding:4px;display:grid}.mode-switch label{background:0 0;border-color:#0000}.mode-switch label:has(input:checked){color:#153f9f;background:#fff;border-color:#b8caf7}.mode-help{margin:7px 0 14px}.primary{background:var(--blue);color:#fff;border-color:var(--blue);width:100%}.primary:hover:not(:disabled){background:#193e9c}.model-state{margin-top:9px}.run-status{margin-top:5px}.run-status.error{color:#9b2416}progress{width:100%;height:9px;accent-color:var(--blue);margin-top:6px;display:block}.matches{border-top:1px solid var(--line);margin-top:13px;padding-top:13px}h2{letter-spacing:-.02em;font-size:1.1rem;line-height:1.3}#unscored{margin-top:4px}.live-banner{background:#eef2f8;border-radius:9px;margin-top:8px;padding:10px 11px}.live-banner p+p{margin-top:4px}.live-badge{color:#153f9f;letter-spacing:.03em;background:#dce6fb;border-radius:20px;padding:2px 8px;font-size:.72rem;font-weight:700;display:inline-block}.live-badge.stable{color:#17643a;background:#d9f2e3}.live-candidates{color:var(--muted);font-size:.82rem}.debug-toggle{cursor:pointer;align-items:center;gap:6px;margin:8px 0;font-size:.875rem;font-weight:600;display:inline-flex}.debug-toggle input{width:16px;height:16px;accent-color:var(--blue)}.top-three{gap:7px;margin-top:8px;display:grid}.match{text-align:left;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:9px;min-height:57px;display:grid}.match small{color:var(--muted);font-variant-numeric:tabular-nums;font-size:.77rem}.match strong{overflow-wrap:anywhere}.match[aria-pressed=true]{border-color:var(--blue);background:#e9f0ff}#score-note{margin-top:5px}.feedback{flex-wrap:wrap;align-items:center;gap:6px;margin-top:9px;display:flex}.feedback p,.feedback .primary{flex-basis:100%}.pokedex-link{color:#204dbc;background:#fff;border-color:#204dbc}.debug{margin-top:20px}.debug-header{justify-content:space-between;align-items:center;gap:8px;display:flex}.metrics,.comparison{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;display:grid}.metrics{grid-template-columns:repeat(auto-fit,minmax(134px,1fr));margin:12px 0}.metrics div,.comparison article{background:#f1f4fa;border-radius:8px;padding:8px 10px}dt,.comparison p{color:var(--muted);font-size:.82rem}dd{overflow-wrap:anywhere;font-variant-numeric:tabular-nums;margin:0;font-size:.95rem}.debug h3{margin:13px 0 7px;font-size:1rem}details{border-top:1px solid var(--line);margin-top:10px;padding:5px 0 0}summary{cursor:pointer;padding:8px 0;font-weight:600}.runs,#top-five{color:var(--muted);margin:0;padding-left:24px;font-size:.875rem}.runs li+li{margin-top:5px}.fixture-buttons{flex-wrap:wrap;gap:6px;padding-bottom:7px;display:flex}.main-tabs{border:1px solid var(--line);background:#e9eef7;border-radius:11px;gap:6px;margin-bottom:16px;padding:4px;display:flex}.main-tabs button{min-height:40px;color:var(--muted);background:0 0;border-color:#0000;flex:1;font-weight:700}.main-tabs button.active,.main-tabs button[aria-selected=true]{color:#153f9f;background:#fff;border-color:#b8caf7;box-shadow:0 1px 3px #1c2c5522}.pokedex-head{justify-content:space-between;align-items:center;gap:12px;margin-bottom:14px;display:flex}.pokedex-toast{color:#17643a;background:#d9f2e3;border-radius:9px;padding:8px 12px;font-size:.9rem;font-weight:700}.pokedex-sub{color:var(--muted);margin-bottom:8px;font-size:.9rem;font-weight:600}.pokedex-generations{gap:6px;padding:3px 0 9px;display:flex;overflow-x:auto}.pokedex-generations button{flex:none;min-height:34px;padding:5px 12px;font-weight:700}.pokedex-generations button.active{color:#fff;background:#153f9f;border-color:#153f9f}.pokedex-tools{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:10px;margin-bottom:10px;display:flex}.pokedex-count{font-variant-numeric:tabular-nums;font-weight:700}.pokedex-tools input{min-width:190px;min-height:40px;padding:7px 11px;font-size:1rem}.pokedex-debug{border:1px solid var(--line);background:#fff;border-radius:10px;margin:0 0 12px;padding:0 11px}.pokedex-grid-wrap{-webkit-overflow-scrolling:touch;max-height:min(62vh,680px);padding:3px;overflow-y:auto}.pokedex-grid{grid-template-columns:repeat(auto-fill,minmax(96px,1fr));gap:9px;display:grid}.dex-tile{border:1px solid var(--line);text-align:center;cursor:pointer;background:#fff;border-radius:11px;flex-direction:column;gap:6px;min-width:0;padding:8px 6px;display:flex}.dex-tile.scanned{background:#fbfffc;border-color:#7cc7a6;box-shadow:inset 0 0 0 1px #7cc7a644}.dex-tile.selected{border-color:#204dbc;box-shadow:0 0 0 2px #204dbc44}.dex-tile-image{aspect-ratio:1;background:#f4f6fb;border-radius:10px;place-items:center;width:100%;padding:8px;display:grid;position:relative;overflow:hidden}.dex-tile-image img{object-fit:contain;width:100%;height:100%;display:block}.dex-tile.not-scanned .dex-art{filter:grayscale(.9);opacity:.78}.dex-tile-image.found-placeholder{background:#eaf6ef}.dex-scan-badge{color:#fff;background:#1d8a58;border-radius:50%;place-items:center;width:18px;height:18px;font-size:.7rem;font-weight:800;display:grid;position:absolute;top:4px;right:4px;box-shadow:0 1px 3px #0004}.dex-unknown-img{opacity:.9}.dex-tile-meta{flex-direction:column;min-width:0;display:flex}.dex-tile-meta strong{text-overflow:ellipsis;white-space:nowrap;font-size:.88rem;overflow:hidden}.dex-tile-meta small{color:var(--muted);font-variant-numeric:tabular-nums;font-size:.73rem}.dex-tile-meta .dex-status{font-size:.68rem}.dex-status.scanned{color:#17643a;font-weight:800}.pokedex-empty{text-align:center;color:var(--muted);grid-column:1/-1;padding:30px 10px}.pokedex-detail{border:1px solid var(--line);background:#fff;border-radius:14px;padding:16px}.pokedex-back{margin-bottom:12px}.detail-hero{align-items:center;gap:16px;display:flex}.detail-image{object-fit:contain;background:#f4f6fb;border-radius:12px;width:140px;height:140px}.detail-number{color:var(--muted);font-variant-numeric:tabular-nums;font-weight:700}.detail-en{color:var(--muted);font-size:.9rem}.detail-fields{grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:9px;margin-top:14px;display:grid}.detail-field{background:#f4f6fb;border-radius:9px;padding:10px}.detail-field-label{color:var(--muted);margin-bottom:3px;font-size:.72rem;display:block}.detail-field strong{font-size:.85rem}.poc-notice{color:#8a5a00;margin-top:12px;font-size:.78rem}body{min-height:100vh;background:radial-gradient(circle at 50% 0,#2b3b4d 0%,#16212e 60%,#0e1620 100%);place-items:center;min-height:100dvh;display:grid;overflow:hidden}.device.device-shell{width:min(430px,100vw);height:100vh;background:linear-gradient(155deg,#3c5163 0%,#263645 42%,#1c2a37 100%);border:1px solid #567084;border-radius:28px;grid-template-rows:auto auto minmax(0,1fr) auto;gap:8px;height:100dvh;max-height:100dvh;margin:0;padding:12px;display:grid;position:relative;overflow:hidden;box-shadow:0 22px 48px #040a12aa,inset 0 2px #70889a55,inset 0 -3px 8px #0a121acc}.device-top{justify-content:space-between;align-items:center;gap:10px;min-height:38px;padding:2px 6px 0;display:flex}.device-brand{color:#cfe0ec;align-items:center;gap:9px;display:flex}.device-lens{background:radial-gradient(circle at 38% 32%,#9fe3d6 0 8%,#2f8f86 26%,#12414a 60%,#0a2029 100%);border:3px solid #5d7486;border-radius:50%;flex:none;width:30px;height:30px;box-shadow:0 0 0 2px #14212e,inset 0 0 6px #000a}.device-brand-text{letter-spacing:.13em;font-size:.68rem;font-weight:800}.device-brand-text b{color:#7fd8c4}.device-leds{gap:8px;display:flex}.led{opacity:.45;background:#0b131b;border-radius:50%;width:10px;height:10px;box-shadow:inset 0 1px 2px #000c}.led.red.active{opacity:1;background:#ff6b6b;box-shadow:0 0 9px #ff6b6b}.led.amber.active{opacity:1;background:#ffc75a;box-shadow:0 0 9px #ffc75a}.led.green.active{opacity:1;background:#5fe0a8;box-shadow:0 0 9px #5fe0a8}.led.pulse{animation:1s ease-in-out infinite ledPulse}@keyframes ledPulse{50%{opacity:.35;transform:scale(.88)}}.device-readout-bar{color:#8ff0cf;background:#0b1b1a;border:1px solid #245049;border-radius:10px;flex:none;align-items:center;gap:10px;height:52px;margin:0;padding:0 12px;font-family:ui-monospace,SFMono-Regular,Consolas,monospace;display:flex;box-shadow:inset 0 0 12px #0008}.readout-caption{letter-spacing:.12em;color:#4f9c86;font-size:.6rem}#device-readout{letter-spacing:.1em;font-size:.95rem}.readout-id{color:#d8fff0;margin-left:auto;font-size:.95rem}.device-screen{overscroll-behavior:contain;-webkit-overflow-scrolling:touch;background:#f4f6fb;border:1px solid #0d1822;border-radius:16px;min-width:0;min-height:0;overflow:hidden auto;box-shadow:inset 0 3px 10px #0006,0 1px #7c94a633}.device-screen main{width:100%;margin:0;padding:0 10px 18px}.screen-nav{z-index:5;background:#f4f6fb;align-items:center;margin:0 -10px;padding:6px 10px 4px;display:flex;position:sticky;top:0}.screen-nav .main-tabs{background:#eef2f8;border-radius:8px;flex:1;min-width:0;margin:0;padding:2px}.screen-nav .main-tabs button{min-height:26px;font-size:.72rem;font-weight:650}.pokedex-toast{z-index:6;position:absolute;top:100%;left:10px;right:10px;box-shadow:0 4px 12px #17223922}#scan-view .stage{aspect-ratio:10/9;border-radius:10px;width:100%;height:auto;max-height:clamp(220px,40dvh,330px)}.scan-hint{letter-spacing:.05em;color:#3f5670;margin-top:8px;font-size:.78rem;font-weight:750}.scan-hint.error{color:#9b2416}#scan-view .image-actions{margin-top:8px}#scan-view .image-actions button,#scan-view .image-actions .file-button{min-height:38px;font-size:.85rem}.recognize-fallback{letter-spacing:.08em;color:#5a6b81;background:#eef2f8;border-color:#cad6e7;width:100%;min-height:36px;margin-top:8px;font-size:.78rem;font-weight:700}.result-panel{border-top:1px solid var(--line);margin-top:10px;padding-top:8px}#scan-view .match{grid-template-columns:20px minmax(0,1fr) auto;gap:6px;min-height:30px;padding:3px 8px;font-size:.82rem}#scan-view .feedback{gap:5px;margin-top:6px}#scan-view .feedback p{font-size:.72rem;display:none}.verify-mode #scan-view .feedback p{display:block}#scan-view .feedback .primary{min-height:38px}#scan-view .pokedex-link{min-height:32px;font-size:.75rem}.menu-overlay{z-index:30;background:#08101ac9;place-items:end center;padding:12px;display:grid;position:absolute;inset:0}.menu-panel{overscroll-behavior:contain;background:#f4f6fb;border:2px solid #5d7486;border-radius:18px;width:100%;max-height:82%;padding:12px;overflow-y:auto;box-shadow:0 16px 40px #0009}.menu-head{justify-content:space-between;align-items:center;gap:8px;margin-bottom:8px;display:flex}.menu-head strong{letter-spacing:.14em;font-size:.8rem;font-weight:800}.menu-close{border-radius:8px;min-width:34px;min-height:34px;padding:0;font-size:1.1rem;line-height:1}.menu-item{text-align:left;width:100%;min-height:44px;margin-top:6px;padding:8px 12px}.menu-lang{border-top:1px solid var(--line);margin-top:10px;padding-top:8px}.menu-lang>span{color:var(--muted);margin-bottom:6px;font-size:.78rem;display:block}.menu-lang .lang-switch{width:max-content}.device-screen .debug{margin-top:12px;padding:12px;font-size:.82rem}.device-screen .debug fieldset{margin-top:8px}.pokedex-sticky{z-index:4;border-bottom:1px solid var(--line);background:#f4f6fb;margin:0 -10px;padding:6px 10px 8px;position:sticky;top:34px}.pokedex-head{margin-bottom:6px}.pokedex-head h2{font-size:1rem}.pokedex-modes{background:#e9eef7;border-radius:8px;gap:4px;margin-bottom:8px;padding:2px;display:flex}.pokedex-modes button{flex:1;min-height:28px;padding:4px 6px;font-size:.72rem}.pokedex-modes button.active{color:#153f9f;background:#fff;border-color:#b8caf7}.pokedex-sub{margin-bottom:5px;font-size:.78rem}.pokedex-generations{padding:2px 0 6px}.pokedex-generations button{min-height:30px;padding:4px 10px;font-size:.78rem}.pokedex-tools{margin-bottom:4px}.pokedex-count{font-size:.78rem}.pokedex-tools input{width:100%;min-width:0;min-height:36px;font-size:.9rem}.pokedex-grid-wrap{max-height:none;padding:2px;overflow:visible}.pokedex-grid{grid-template-columns:repeat(auto-fill,minmax(84px,1fr));gap:7px}.dex-tile{padding:6px 4px}.pokedex-detail{padding:12px}.detail-hero{gap:10px}.detail-image{width:104px;height:104px}.detail-fields{grid-template-columns:1fr;gap:7px;margin-top:10px}.detail-field{padding:8px}.device-controls{min-height:104px;padding:6px 4px calc(2px + env(safe-area-inset-bottom));grid-template-columns:1fr auto 1fr;align-items:center;gap:8px;display:grid}.device-ab{justify-self:start;gap:10px;display:flex}.device-btn{font:inherit;cursor:pointer;color:#eaf3f8;-webkit-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent;background:linear-gradient(160deg,#4d6478,#2a3a49);border:1px solid #6b8296;transition:transform 80ms,box-shadow 80ms;box-shadow:0 5px #14202b,0 8px 14px #0006,inset 0 1px #9fb4c455}.device-btn:focus-visible{outline-offset:2px;outline:3px solid #7fd8c4}.device-btn.pressed{transform:translateY(4px)scale(.97);box-shadow:0 1px #14202b,0 3px 6px #0006,inset 0 1px #9fb4c455}.device-btn.round{border-radius:50%;width:52px;height:52px;font-size:1.05rem;font-weight:800}#device-a{background:linear-gradient(160deg,#3aa88f,#1c6c60);border-color:#57c9b2;box-shadow:0 5px #0d3b36,0 8px 14px #0006,inset 0 1px #bff3e555}.device-btn.menu{letter-spacing:.1em;border-radius:10px;justify-self:center;min-height:44px;padding:9px 12px;font-size:.68rem;font-weight:800}.device-dpad{grid-template-rows:repeat(3,36px);grid-template-columns:repeat(3,36px);justify-self:end;gap:2px;display:grid}.device-btn.dpad{border-radius:8px;padding:0;font-size:.78rem;box-shadow:0 4px #14202b,0 6px 10px #0006,inset 0 1px #9fb4c455}.device-btn.dpad.up{grid-area:1/2}.device-btn.dpad.left{grid-area:2/1}.device-btn.dpad.right{grid-area:2/3}.device-btn.dpad.down{grid-area:3/2}.dpad-center{background:#14212e;border-radius:50%;grid-area:2/2;place-self:center;width:10px;height:10px;box-shadow:inset 0 1px 2px #000}@media (width<=700px){.device.device-shell{width:100vw;height:100vh;height:100dvh;max-height:100dvh;padding:10px 8px calc(8px + env(safe-area-inset-bottom));border:0;border-radius:0;gap:6px}.device-top{padding:0 4px}.device-brand-text{font-size:.6rem}.device-lens{width:26px;height:26px}.device-readout-bar{height:46px;padding:0 10px}.readout-caption{display:none}.device-screen main{padding:0 8px 14px}.screen-nav{margin:0 -8px;padding:6px 8px 4px}.screen-nav .main-tabs button{min-height:24px;font-size:.7rem}.pokedex-sticky{margin:0 -8px;padding:6px 8px;top:32px}#scan-view .stage{max-height:clamp(200px,40dvh,320px)}.device-controls{min-height:96px;padding:4px 2px 2px}.device-btn.round{width:50px;height:50px}.device-dpad{grid-template-rows:repeat(3,34px);grid-template-columns:repeat(3,34px)}.device-btn.menu{padding:8px 10px;font-size:.65rem}.pokedex-grid{grid-template-columns:repeat(auto-fill,minmax(78px,1fr));gap:6px}.pokedex-tools input{width:100%}}
