/* BinderWorth Scanner Refresh · experimental 3.41.0
 * Mobile-only camera-first flow. No collection or challenge logic here.
 * Loaded AFTER all legacy/brand styles so it can cleanly own mobile scanner.
 */

#scanView .pokeum-admin-tools { border:1px solid rgba(110,216,180,.27); border-radius:13px; margin:8px 0 14px; background:rgba(9,31,33,.78); color:#d5efe8; }
#scanView .pokeum-admin-tools > summary { cursor:pointer; list-style:none; display:flex; align-items:center; justify-content:space-between; gap:8px; padding:11px 13px; font-size:12px; font-weight:750; }
#scanView .pokeum-admin-tools > summary::-webkit-details-marker {display:none;}
#scanView .pokeum-admin-tools > summary b {font-size:9px;letter-spacing:.08em;color:#77d7b8;white-space:nowrap;}
#scanView .pokeum-admin-body {display:grid;gap:10px;padding:12px;border-top:1px solid rgba(110,216,180,.17);}
#scanView .pokeum-admin-body label {font-size:12px;color:#d5efe8;display:grid;gap:6px;}
#scanView .pokeum-admin-body input[type="password"] {box-sizing:border-box;width:100%;min-width:0;min-height:44px;background:#07181d;color:#e9fffa;border:1px solid #35565b;border-radius:9px;padding:10px 12px;font-size:16px;}
#scanView .pokeum-admin-body .pokeum-switch {display:flex;align-items:center;gap:10px;padding:10px;border:1px solid rgba(110,216,180,.2);border-radius:10px;}
#scanView .pokeum-switch input {width:20px;height:20px;accent-color:#67d5b7;flex:none;}
#scanView .pokeum-admin-body p {margin:0;color:#a6c4c0;line-height:1.45;font-size:11px;}
#scanView .pokeum-result-banner {border:1px solid rgba(99,211,175,.35);border-radius:16px;padding:15px;background:linear-gradient(145deg,#112c2a,#0d1c26);color:#e6f9f3;}
#scanView .pokeum-result-banner strong {display:block;font-size:15px;margin-bottom:5px;color:#e6fff6;}
#scanView .pokeum-result-banner p {margin:0;font-size:12px;line-height:1.5;color:#b9d8d2;}
#scanView .pokeum-result-banner .pokeum-proof {display:flex;gap:7px;flex-wrap:wrap;margin-top:10px;}
#scanView .pokeum-proof span {padding:5px 9px;border-radius:999px;background:#0a2223;color:#b9ecd8;font-size:11px;border:1px solid rgba(99,211,175,.2);}
#scanView .pokeum-result-list {display:grid;gap:10px;}
#scanView .pokeum-result-list .pokeum-card-option {display:grid;grid-template-columns:76px minmax(0,1fr);gap:13px;align-items:center;border:1px solid rgba(150,175,182,.2);border-radius:15px;padding:12px;background:#101c26;color:#f0f8fb;min-width:0;}
#scanView .pokeum-card-option:first-child {border-color:rgba(110,216,180,.52);box-shadow:inset 3px 0 #67d5b7;}
#scanView .pokeum-card-option img,#scanView .pokeum-card-option .pokeum-empty-art {width:76px;height:105px;object-fit:contain;border-radius:7px;background:#0a1119;color:#9aafb9;display:grid;place-items:center;font-size:11px;text-align:center;}
#scanView .pokeum-card-option .pokeum-card-copy {min-width:0;display:grid;gap:4px;}
#scanView .pokeum-card-copy strong {font-size:16px;line-height:1.25;overflow-wrap:anywhere;}
#scanView .pokeum-card-copy .pokeum-set-line {font-size:12px;color:#bbcad3;overflow-wrap:anywhere;}
#scanView .pokeum-card-copy .pokeum-evidence {font-size:11px;color:#8ddbbf;font-weight:700;}
#scanView .pokeum-card-option .pokeum-card-action {grid-column:1/-1;}
#scanView .pokeum-card-action button {width:100%;min-height:48px;}
#scanView .pokeum-disclaimer {font-size:12px;line-height:1.5;color:#b8c6cf;margin:8px 0 0;}
#scanView .pokeum-legacy-button {width:100%;min-height:46px;margin:6px 0 0;}

@media (max-width:780px) {
  /* Full-width phone composition, including narrow folded devices (320–400px). */
  html body #scanView.active {display:grid;gap:9px;min-width:0;padding:0 0 calc(26px + env(safe-area-inset-bottom, 0px))!important;}
  html body #scanView .scan-intro {display:grid!important;grid-template-columns:1fr!important;gap:10px!important;margin:0!important;padding:14px 14px 11px!important;border-radius:15px!important;}
  html body #scanView .scan-intro h2 {font-size:clamp(24px,7vw,30px)!important;line-height:1.08!important;margin:3px 0 5px!important;letter-spacing:-.035em!important;}
  html body #scanView .scan-intro p {font-size:12px!important;line-height:1.45!important;max-width:45ch;}
  html body #scanView .scan-intro .ai-chip {font-size:9px!important;letter-spacing:.09em!important;}
  html body #scanView .scan-stepper {display:grid!important;grid-template-columns:minmax(0,1fr) 12px minmax(0,1fr) 12px minmax(0,1fr)!important;justify-content:stretch!important;width:100%!important;gap:4px!important;}
  html body #scanView .scan-stepper span {display:flex!important;align-items:center;justify-content:center;gap:6px!important;font-size:10px!important;white-space:nowrap!important;}
  html body #scanView .scan-stepper b {width:23px;height:23px;min-width:23px;border-radius:50%;font-size:11px;}
  html body #scanView .scan-stepper i {width:12px!important;max-width:12px!important;height:1px;align-self:center;}
  html body #scanView .scan-help {margin:0!important;background:transparent!important;}
  html body #scanView .scan-help summary {font-size:12px!important;padding:10px 12px!important;}
  html body #scanView .scan-warning.compact {margin:0!important;padding:9px 11px!important;gap:8px;align-items:center;}
  html body #scanView .scan-warning.compact strong {font-size:11px!important;}
  html body #scanView .scan-warning.compact p {display:none;}
  html body #scanView .scan-grid {display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:9px!important;padding-bottom:0!important;min-width:0;}
  html body #scanView .capture-panel {padding:11px!important;border-radius:16px!important;min-width:0!important;overflow:visible!important;}
  html body #scanView .scan-capture-heading {display:flex!important;align-items:center!important;flex-wrap:wrap;gap:5px;margin-bottom:10px!important;}
  html body #scanView .scan-capture-heading .eyebrow {display:none;}
  html body #scanView .scan-capture-heading h3 {font-size:16px!important;margin:0!important;}
  html body #scanView .scan-capture-heading .service-pill {font-size:10px!important;line-height:1.3;}
  html body #scanView .capture-stage {position:relative!important;width:100%!important;height:clamp(335px,55svh,480px)!important;min-height:335px!important;max-height:480px!important;border-radius:16px!important;border:1px solid rgba(150,175,190,.21)!important;background:radial-gradient(circle at 50% 34%,#1a2b36,#09121b 72%)!important;touch-action:manipulation;}
  html body #scanView .capture-stage.camera-active video {object-fit:cover!important;}
  html body #scanView .card-guide {width:min(72%,270px)!important;max-height:90%!important;border-radius:10px!important;border-color:rgba(255,255,255,.86)!important;}
  html body #scanView .card-guide::before,html body #scanView .card-guide::after {border-radius:9px!important;}
  html body #scanView .scan-placeholder {max-width:260px!important;padding:14px!important;}
  html body #scanView .scan-placeholder .camera-symbol {width:72px!important;height:72px!important;font-size:31px!important;border-radius:24px!important;margin-bottom:15px!important;transform:none!important;background:linear-gradient(145deg,#54d4c0,#2495bc)!important;}
  html body #scanView .scan-placeholder strong {font-size:20px!important;line-height:1.18!important;margin:0 0 8px!important;}
  html body #scanView .scan-placeholder span {font-size:13px!important;line-height:1.4!important;color:#adbdc8!important;}
  html body #scanView .scan-placeholder em {display:none!important;}
  html body #scanView .scan-stage-cta {display:none!important;}
  html body #scanView .capture-stage.camera-active .scan-stage-cta {position:absolute;left:8%;right:8%;bottom:15px;display:flex!important;flex-direction:column!important;align-items:center!important;text-align:center!important;gap:4px!important;pointer-events:none;background:rgba(5,16,22,.7);border:1px solid rgba(255,255,255,.14);border-radius:12px;padding:9px!important;}
  html body #scanView .scan-stage-cta strong {display:block;font-size:13px;}
  html body #scanView .scan-stage-cta span {display:block;font-size:11px;}
  html body #scanView .scan-actions {display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;gap:8px!important;position:sticky!important;bottom:calc(8px + env(safe-area-inset-bottom, 0px))!important;z-index:16!important;margin:10px 0 0!important;padding:9px!important;border:1px solid rgba(138,173,182,.22)!important;border-radius:15px!important;background:rgba(10,20,29,.96)!important;box-shadow:0 10px 34px rgba(0,0,0,.35)!important;backdrop-filter:blur(12px);}
  html body #scanView .scan-actions > .button,html body #scanView .scan-actions > .file-button {min-height:54px!important;border-radius:12px!important;font-size:13px!important;font-weight:800!important;line-height:1.25!important;white-space:normal!important;padding:10px!important;min-width:0!important;}
  html body #scanView .scan-actions #startCameraBtn {grid-column:1!important;}
  html body #scanView.scan-ux-camera .scan-actions #captureCardBtn {grid-column:1!important;font-size:17px!important;letter-spacing:-.02em!important;background:#66d5b6!important;color:#06201c!important;}
  html body #scanView.scan-ux-camera .scan-actions .scan-gallery-button {grid-column:2!important;}
  html body #scanView.scan-ux-photo .scan-actions #identifyCardBtn {grid-column:1 / -1!important;margin:0!important;font-size:16px!important;min-height:58px!important;}
  html body #scanView.scan-ux-photo .scan-actions .scan-gallery-button {grid-column:1 / -1!important;min-height:44px!important;background:transparent!important;}
  html body #scanView .crop-tools {margin-top:10px!important;}
  html body #scanView .crop-tools > summary {padding:11px 12px!important;}
  html body #scanView .scan-privacy {margin-top:9px!important;}
  html body #scanView .scan-result-panel {padding:12px!important;border-radius:16px!important;min-width:0!important;scroll-margin-top:72px!important;}
  html body #scanView .scan-result-heading h3 {font-size:18px!important;line-height:1.16!important;}
  html body #scanView .scan-result-heading small {font-size:11px!important;line-height:1.4!important;}
  html body #scanView .scan-status {min-height:145px!important;padding:16px 10px!important;}
  html body #scanView .scan-status-icon {width:48px!important;height:48px!important;font-size:23px!important;}
  html body #scanView .scan-readout {padding:0!important;margin-bottom:10px!important;}
  html body #scanView .scanner-confidence-card {display:flex!important;align-items:center;gap:11px;padding:12px!important;}
  html body #scanView .scanner-confidence-card strong {font-size:16px!important;line-height:1.25!important;}
  html body #scanView .scanner-confidence-card p {font-size:11px!important;line-height:1.35!important;}
  html body #scanView .scanner-confidence-card > b {width:55px!important;min-width:55px!important;height:55px!important;min-height:55px!important;font-size:17px!important;}
  html body #scanView .scan-advanced-details > summary {padding:11px 12px!important;gap:6px!important;}
  html body #scanView .scan-advanced-details > summary small {white-space:normal!important;}
  html body #scanView .scan-advanced-body {padding:11px!important;}
  html body #scanView .scan-candidates {min-width:0!important;gap:9px!important;}
  html body #scanView .scan-candidate,html body #scanView .scan-more-list .scan-candidate {display:grid!important;grid-template-columns:74px minmax(0,1fr)!important;gap:10px!important;min-width:0!important;padding:11px!important;}
  html body #scanView .scan-candidate img {width:72px!important;height:102px!important;object-fit:contain!important;}
  html body #scanView .scan-candidate h4 {font-size:16px!important;line-height:1.2!important;}
  html body #scanView .scan-candidate p {font-size:11px!important;line-height:1.4!important;}
  html body #scanView .scan-candidate-copy {min-width:0!important;overflow-wrap:anywhere!important;}
  html body #scanView .candidate-badges {display:flex!important;flex-wrap:wrap!important;gap:4px!important;}
  html body #scanView .match-badge {white-space:normal!important;line-height:1.25!important;}
  html body #scanView .scan-candidate-actions {grid-column:1/-1!important;min-width:0!important;display:block!important;}
  html body #scanView .scan-candidate-actions .button {width:100%!important;min-height:50px!important;}
  html body #scanView .scan-more-matches {min-width:0!important;overflow:hidden!important;}
  html body #scanView .scan-feedback-panel {display:grid!important;gap:11px!important;padding:12px!important;}
  html body #scanView .scan-feedback-panel .button {width:100%!important;min-width:0!important;}
  html body #scanView .pokeum-card-option {grid-template-columns:64px minmax(0,1fr)!important;gap:10px!important;padding:10px!important;}
  html body #scanView .pokeum-card-option img,html body #scanView .pokeum-card-option .pokeum-empty-art {width:64px!important;height:88px!important;}
  html body #scanView .pokeum-card-copy strong {font-size:15px!important;}

  /* Results first: compress the large camera preview into a small review strip.
     Camera/file source still exists and can be replaced normally. */
  html body #scanView.scan-ux-results .capture-panel,html body #scanView.scan-ux-error .capture-panel {padding:7px!important;}
  html body #scanView.scan-ux-results .scan-capture-heading,html body #scanView.scan-ux-error .scan-capture-heading,
  html body #scanView.scan-ux-results .crop-tools,html body #scanView.scan-ux-results .scan-privacy,
  html body #scanView.scan-ux-results .scan-actions,
  html body #scanView.scan-ux-error .scan-privacy {display:none!important;}
  html body #scanView.scan-ux-results .capture-stage,html body #scanView.scan-ux-error .capture-stage {height:106px!important;min-height:106px!important;max-height:106px!important;border-radius:11px!important;}
  html body #scanView.scan-ux-results .capture-stage > img {object-fit:contain!important;}
  html body #scanView.scan-ux-results .scan-grid {gap:7px!important;}
}
@media(max-width:370px) {
  html body #scanView .scan-intro {padding:12px!important;}
  html body #scanView .scan-capture-heading .service-pill {font-size:9px!important;}
  html body #scanView .scan-actions {padding:7px!important;gap:6px!important;}
  html body #scanView .scan-actions > .button,html body #scanView .scan-actions > .file-button {font-size:12px!important;padding:8px!important;}
}
@media(prefers-reduced-motion:reduce) {
  #scanView .capture-stage *,#scanView .scan-status-icon {animation:none!important;transition:none!important;}
}
/* Navigation isolation: this is a SPA view, not a persistent page overlay.
   A non-active scanner must remain hidden at every viewport size. */
html body #scanView:not(.active) {display:none!important;}
