/* PraxTools Image to Excel Pro */
:root{--red:#ef2b2d;--red2:#b91c1c;--ink:#171923;--muted:#737783;--paper:#f5f6fb;--card:#fff;--border:#e4e6ed;--green:#138a61;--greenbg:#effaf5;--shadow:0 18px 50px rgba(20,24,40,.08)}
*{box-sizing:border-box}body{margin:0;background:var(--paper);color:var(--ink);font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif}.top{min-height:76px;background:rgba(255,255,255,.96);border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;padding:12px clamp(16px,5vw,72px);position:sticky;top:0;z-index:10;backdrop-filter:blur(14px)}.brand{display:flex;align-items:center;gap:11px;text-decoration:none;color:var(--ink)}.logo{width:42px;height:42px;border-radius:13px;background:linear-gradient(135deg,var(--red),var(--red2));color:#fff;display:grid;place-items:center;font-weight:900;font-size:22px;box-shadow:0 8px 22px rgba(239,43,45,.2)}.brand b{font-size:20px}.brand small{display:block;color:#80838e;font-size:9px;letter-spacing:1.2px;margin-top:2px}.site-nav{display:flex;gap:6px}.site-nav a{color:#555967;text-decoration:none;font-size:13px;font-weight:700;padding:9px 12px;border-radius:9px}.site-nav a:hover{background:#fff0f0;color:var(--red)}.wrapper{width:calc(100% - 28px);max-width:920px;margin:42px auto;padding:34px;background:var(--card);border:1px solid var(--border);border-radius:22px;box-shadow:var(--shadow);position:relative;overflow:hidden}.wrapper:before{content:"";position:absolute;top:0;left:0;right:0;height:5px;background:linear-gradient(90deg,var(--red),#ff7373)}.badge{display:inline-flex;background:#fff0f0;color:var(--red2);font-size:11px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;padding:6px 12px;border-radius:999px;margin-bottom:13px}h1{font-size:30px;letter-spacing:-.7px;margin:0 0 7px}.subtitle{color:var(--muted);font-size:14px;line-height:1.65;max-width:720px;margin:0 0 24px}.form-box{background:#fafbfe;border:1px solid var(--border);border-radius:18px;padding:22px}.field{margin-bottom:18px}label{display:block;font-size:12px;font-weight:800;color:#686c78;letter-spacing:.05em;text-transform:uppercase;margin-bottom:8px}.dropzone{position:relative;border:2px dashed #d9dce5;border-radius:15px;background:#fff;padding:38px 18px;text-align:center;cursor:pointer;transition:.2s}.dropzone:hover,.dropzone.dragover{border-color:var(--red);background:#fff8f8}.dropzone input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.dropzone-icon{font-size:32px}.dropzone-title{font-size:15px;font-weight:800;margin-top:8px}.dropzone-hint{font-size:12px;color:var(--muted);margin-top:5px}.preview-wrap{display:none;align-items:center;gap:12px;background:#fff;border:1px solid var(--border);border-radius:12px;padding:10px;margin-top:12px}.preview-wrap.active{display:flex}.preview-wrap img{width:62px;height:62px;object-fit:cover;border-radius:9px;border:1px solid var(--border)}.preview-meta{flex:1;min-width:0}.preview-name{font-size:13px;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.preview-size{font-size:12px;color:var(--muted);margin-top:3px}.preview-remove{border:0;background:#fff0f0;color:#c52c2e;width:30px;height:30px;border-radius:50%;font-size:18px;cursor:pointer}.row-2{display:grid;grid-template-columns:1fr 1fr;gap:14px}select{width:100%;padding:12px;border:1px solid #d8dbe4;border-radius:10px;background:#fff;color:var(--ink);font-size:14px}.check{display:flex;gap:9px;align-items:center;text-transform:none;letter-spacing:0;color:#565a67;font-weight:600;font-size:13px;margin:8px 0 0}.check input{accent-color:var(--red);width:17px;height:17px}button[type=submit]{width:100%;border:0;border-radius:11px;background:linear-gradient(135deg,var(--red),#d51e21);color:#fff;font-size:15px;font-weight:800;padding:14px;margin-top:20px;cursor:pointer;display:flex;justify-content:center;align-items:center;gap:8px;box-shadow:0 9px 20px rgba(239,43,45,.18)}button:disabled{opacity:.7}.spinner{display:none;width:16px;height:16px;border:2px solid rgba(255,255,255,.35);border-top-color:#fff;border-radius:50%;animation:spin .7s linear infinite}.btn-loading .spinner{display:block}.btn-loading .btn-label{font-size:0}.btn-loading .btn-label:after{content:"Analyzing image…";font-size:15px}@keyframes spin{to{transform:rotate(360deg)}}.info-note{margin-top:18px;background:#fff7f2;border-left:4px solid #f08a46;padding:14px 16px;border-radius:9px;font-size:13px;color:#76513a;line-height:1.55}.how{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-top:24px}.how div{border:1px solid var(--border);border-radius:12px;padding:13px;background:#fff;display:flex;align-items:center;gap:9px;font-size:12px;color:#5f6370;font-weight:700}.how b{width:27px;height:27px;border-radius:50%;display:grid;place-items:center;background:#fff0f0;color:var(--red)}.success-box,.error-box{display:flex;gap:13px;padding:16px;border-radius:12px;margin-bottom:18px}.success-box{background:var(--greenbg);border:1px solid #ccebdc;color:#176c50}.error-box{background:#fff0f0;border:1px solid #f5c9c9;color:#a92b2d}.icon{font-size:21px}.success-box p{margin:4px 0 5px}.download-btn{display:inline-flex;background:var(--green);color:#fff;text-decoration:none;border-radius:9px;padding:9px 14px;font-weight:800;font-size:13px}.notes,.debug{background:#f8f9fc;border:1px solid var(--border);border-radius:10px;padding:12px;margin-bottom:18px;font-size:12px;color:#646875}.debug{margin-top:10px}.result h2{font-size:19px;margin:18px 0 10px}.preview-box{border:1px solid var(--border);border-radius:13px;overflow:auto;max-height:540px;background:#fff}.preview-box table{border-collapse:collapse;width:100%;min-width:640px;font-size:13px}.preview-box th,.preview-box td{border:1px solid #e1e3e9;padding:9px 10px;text-align:left;vertical-align:top;white-space:nowrap}.preview-box th{position:sticky;top:0;background:#f1f4f8;font-weight:800;z-index:1}.preview-box tr:nth-child(even) td{background:#fbfcfe}.preview-caption{text-align:center;color:var(--muted);font-size:12px;line-height:1.5;margin:10px}.back-link{display:block;text-align:center;margin-top:22px;color:var(--ink);font-weight:800;text-decoration:none}.site-footer{margin-top:44px;background:#171923;color:#fff}.footer-inner{max-width:1200px;margin:auto;padding:24px clamp(18px,5vw,60px);display:flex;justify-content:space-between;gap:20px}.site-footer span{color:#aeb2bf;font-size:12px;margin-left:10px}.footer-links{display:flex;gap:15px}.footer-links a{color:#dfe1e8;text-decoration:none;font-size:12px}@media(max-width:700px){.wrapper{padding:25px 18px;margin-top:25px}h1{font-size:24px}.row-2,.how{grid-template-columns:1fr}.top{min-height:64px;padding:9px 14px}.brand b{font-size:18px}.logo{width:37px;height:37px}.site-nav{display:none}.footer-inner{flex-direction:column}.site-footer span{display:block;margin:5px 0 0}}
.progress-overlay{display:none;position:fixed;inset:0;background:rgba(23,25,35,.55);backdrop-filter:blur(3px);z-index:100;align-items:center;justify-content:center;padding:20px}.progress-overlay.active{display:flex}.progress-card{background:#fff;border-radius:18px;padding:28px 26px;max-width:360px;width:100%;box-shadow:0 25px 60px rgba(0,0,0,.25);text-align:center}.progress-ring{width:40px;height:40px;border:4px solid #f1d2d2;border-top-color:var(--red);border-radius:50%;margin:0 auto 14px;animation:spin .8s linear infinite}.progress-title{font-weight:800;font-size:16px;margin-bottom:18px;color:var(--ink)}.progress-steps{list-style:none;margin:0;padding:0;text-align:left;display:flex;flex-direction:column;gap:12px}.progress-steps .step{display:flex;align-items:center;gap:10px;font-size:13px;color:#9a9ea9;font-weight:700;transition:.25s}.progress-steps .step-mark{width:22px;height:22px;border-radius:50%;border:2px solid #e1e3ea;display:grid;place-items:center;font-size:11px;flex:0 0 auto;transition:.25s;color:#9a9ea9}.progress-steps .step.active{color:var(--ink)}.progress-steps .step.active .step-mark{border-color:var(--red);color:var(--red)}.progress-steps .step.done{color:#137a4e}.progress-steps .step.done .step-mark{background:var(--green);border-color:var(--green);color:#fff;font-size:0}.progress-steps .step.done .step-mark:before{content:"✓";font-size:12px}.progress-hint{margin-top:16px;font-size:11px;color:var(--muted)}

.engine-lock{min-height:46px;display:flex;align-items:center;gap:10px;padding:10px 12px;border:1px solid #d8dbe4;border-radius:10px;background:#fff}.engine-lock>span{width:28px;height:28px;border-radius:8px;display:grid;place-items:center;background:#fff0f0;color:var(--red);font-weight:900}.engine-lock b{display:block;font-size:13px}.engine-lock small{display:block;color:var(--muted);font-size:11px;margin-top:2px}

.retry-box{display:flex;gap:13px;padding:18px;border-radius:14px;background:#fff8f0;border:1px solid #f0d7b5;color:#7a5227}.retry-box p{margin:5px 0 12px;line-height:1.5}.retry-btn{background:var(--red)}

/* PraxTools unified visual layer */
:root{--accent:#e11d2e}button,.btn,input,select,textarea{border-radius:11px}.card,.panel,.upload-box{border-radius:18px;box-shadow:0 10px 28px rgba(15,23,42,.055)}

/* Helpful content below the converter. */
.excel-guide{margin:32px 0;padding:24px;background:#fff;border:1px solid #e5e7eb;border-radius:16px;color:#222;line-height:1.7;overflow-wrap:anywhere}
.excel-guide h2{font-size:23px;line-height:1.3;margin:28px 0 12px}.excel-guide h2:first-child{margin-top:0}.excel-guide h3{font-size:18px;margin:20px 0 8px}.excel-guide ol,.excel-guide ul{padding-left:24px}.excel-guide li{margin:8px 0}.excel-guide a{color:#ad0020;text-decoration:underline}.excel-guide details{padding:14px 0;border-bottom:1px solid #e5e7eb}.excel-guide summary{cursor:pointer;font-weight:600}.excel-guide details p{margin:10px 0 0}.excel-guide-table{overflow-x:auto}.excel-guide table{width:100%;border-collapse:collapse}.excel-guide th,.excel-guide td{padding:10px;border:1px solid #ddd;text-align:left}.excel-guide th{background:#fff3f4}.excel-guide caption{text-align:left;font-weight:600;padding:8px 0}@media(max-width:600px){.excel-guide{padding:16px}.excel-guide h2{font-size:20px}}


/* V8 DESIGN LAYER — visual only; conversion logic unchanged */
.image-to-excel-page{background:linear-gradient(180deg,#fff 0,#fff8f8 48%,#f8fafc 100%)}
.image-to-excel-page .wrapper{max-width:1050px;margin:auto;padding:34px 16px 64px}.excel-hero{text-align:center;margin-bottom:26px}.excel-hero .eyebrow{display:inline-flex;padding:7px 12px;border-radius:999px;background:#fff1f2;border:1px solid #fecdd3;color:#be123c;font-size:12px;font-weight:900;letter-spacing:.05em;text-transform:uppercase}.excel-hero h1{font-size:clamp(32px,6vw,50px);line-height:1.08;margin:10px 0 12px}.excel-hero .subtitle{max-width:760px;margin:auto;color:var(--muted,#667085);font-size:16px;line-height:1.7}
.excel-panel{max-width:820px;margin:0 auto;background:#fff;border:1px solid var(--line,#e5e7eb);border-radius:22px;padding:clamp(18px,4vw,30px);box-shadow:0 18px 55px rgba(15,23,42,.08)}.field{margin-bottom:17px}.field>label{display:block;font-weight:850;margin:0 0 8px}.dropzone{position:relative;min-height:245px;border:2px dashed #d8dce5;border-radius:18px;background:#fafbfe;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:26px;cursor:pointer;transition:.2s}.dropzone:hover,.dropzone.dragover{border-color:#ef9aa4;background:#fff7f8;transform:translateY(-1px)}.dropzone input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.dropzone-icon{font-size:42px}.dropzone-title{font-size:18px;font-weight:900;margin-top:9px}.dropzone-hint{margin-top:7px;color:var(--muted,#667085);font-size:13px;line-height:1.5}.preview-wrap{display:none;position:relative;margin-top:12px;padding:12px;border:1px solid var(--line,#e5e7eb);border-radius:15px;background:#fff}.preview-wrap.active{display:grid;grid-template-columns:76px 1fr auto;gap:12px;align-items:center}.preview-wrap img{width:76px;height:76px;object-fit:cover;border-radius:10px;background:#f4f4f5}.preview-name{font-weight:850;overflow-wrap:anywhere}.preview-size{font-size:12px;color:var(--muted,#667085);margin-top:4px}.preview-remove{width:34px;height:34px;border-radius:50%;border:0;background:#f3f4f6;font-size:22px;cursor:pointer}.row-2{display:grid;grid-template-columns:1fr 1fr;gap:14px}.field select{width:100%;padding:13px;border:1px solid var(--line,#e5e7eb);border-radius:12px;background:#fff;font:inherit}.field select:focus{outline:0;border-color:#ef9aa4;box-shadow:0 0 0 4px rgba(225,29,46,.08)}.check{display:flex;gap:9px;align-items:flex-start;color:#475467;font-size:13px;line-height:1.5;margin:5px 0 17px}.excel-panel>button[type=submit],.download-btn{width:100%;border:0;border-radius:12px;padding:14px 18px;background:#e11d2e;color:#fff;font-weight:900;font-size:15px;cursor:pointer;box-shadow:0 8px 20px rgba(225,29,46,.18)}.excel-panel>button[type=submit]:hover,.download-btn:hover{filter:brightness(.96);transform:translateY(-1px)}.excel-panel>button[disabled]{opacity:.65;cursor:not-allowed}.info-note{max-width:820px;margin:14px auto 0;padding:14px 16px;border-radius:13px;background:#fff7ed;border:1px solid #fed7aa;color:#7c2d12;font-size:13px}.how{max-width:820px;margin:20px auto;display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.how>div{background:#fff;border:1px solid var(--line,#e5e7eb);border-radius:14px;padding:14px;text-align:center}.how b{display:grid;place-items:center;width:30px;height:30px;margin:0 auto 8px;border-radius:50%;background:#fff1f2;color:#be123c}.how span{font-size:12px;font-weight:750}.excel-guide{max-width:820px;margin:34px auto 0;background:#fff;border:1px solid var(--line,#e5e7eb);border-radius:20px;padding:clamp(18px,4vw,28px);line-height:1.75}.excel-guide h2{margin-top:24px}.excel-guide h2:first-child{margin-top:0}.excel-guide-table{overflow:auto}.excel-guide table{width:100%;border-collapse:collapse}.excel-guide th,.excel-guide td{padding:10px;border:1px solid #e5e7eb;text-align:left}.excel-guide th{background:#f8fafc}.progress-overlay{position:fixed;inset:0;background:rgba(15,23,42,.58);display:none;place-items:center;z-index:9999;padding:18px;backdrop-filter:blur(5px)}.progress-overlay.active{display:grid}.progress-card{width:min(460px,100%);background:#fff;border-radius:22px;padding:28px;box-shadow:0 30px 80px rgba(0,0,0,.2)}.progress-ring{width:46px;height:46px;border:4px solid #ffe4e6;border-top-color:#e11d2e;border-radius:50%;animation:spin .8s linear infinite;margin:0 auto 14px}.progress-title{text-align:center;font-size:19px;font-weight:900}.progress-steps{list-style:none;padding:0;margin:20px 0}.step{display:flex;align-items:center;gap:10px;padding:8px 0;color:#98a2b3}.step-mark{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#f2f4f7;font-size:12px;font-weight:900}.step.active{color:#101828;font-weight:800}.step.active .step-mark,.step.done .step-mark{background:#e11d2e;color:#fff}.progress-hint{text-align:center;color:#667085;font-size:12px;line-height:1.5}.retry-box{max-width:650px;margin:80px auto;background:#fff;border:1px solid #e5e7eb;border-radius:20px;padding:28px;display:flex;gap:16px}.retry-box .icon{font-size:34px}.result-card{max-width:1000px;margin:30px auto;background:#fff;border:1px solid #e5e7eb;border-radius:20px;padding:22px;box-shadow:0 18px 55px rgba(15,23,42,.08)}.table-wrap{overflow:auto;border:1px solid #e5e7eb;border-radius:12px}.table-wrap table{border-collapse:collapse;width:max-content;min-width:100%}.table-wrap th,.table-wrap td{border:1px solid #e5e7eb;padding:8px 10px;white-space:pre-wrap}.table-wrap th{position:sticky;top:0;background:#f8fafc}.spinner{display:none}.btn-loading .spinner{display:inline-block;width:15px;height:15px;border:2px solid rgba(255,255,255,.45);border-top-color:#fff;border-radius:50%;animation:spin .7s linear infinite;margin-right:8px;vertical-align:-2px}@keyframes spin{to{transform:rotate(360deg)}}
@media(max-width:760px){.image-to-excel-page .wrapper{padding:24px 12px 48px}.row-2,.how{grid-template-columns:1fr}.dropzone{min-height:210px}.excel-panel{border-radius:17px}.preview-wrap.active{grid-template-columns:58px 1fr auto}.preview-wrap img{width:58px;height:58px}.excel-guide{border-radius:16px}}


/* Image-to-Excel result page: stat pills, plain <td>-only preview tables,
   and low-confidence cell highlighting (rebrand from AbWap.In to PraxTools). */
.stat-row{display:flex;gap:10px;margin-bottom:18px;flex-wrap:wrap}
.stat-pill{background:#f7f8fc;border:1px solid #e4e6ed;color:#171923;font-size:12.5px;font-weight:800;padding:6px 14px;border-radius:999px}
.preview-box tr:first-child td{background:#f1f4f8;font-weight:800;font-family:Inter,sans-serif}
.preview-box tr:nth-child(even) td{background:#fbfcfe}
.preview-box td.low-conf{background:#fff7cf!important}
.error-box a{color:inherit;text-decoration:underline}
.error-box code,.info-note code{background:rgba(0,0,0,.06);padding:1px 6px;border-radius:5px;font-size:12px}

/* Defensive override: some shared site stylesheets hide <main> by default
   (assuming JS reveals it) or collapse it via floats. Force this tool's
   result container to always be visible regardless of that. */
body.image-to-excel-page main.wrapper{
  display:block!important;
  visibility:visible!important;
  opacity:1!important;
  height:auto!important;
  min-height:120px!important;
  max-height:none!important;
  overflow:visible!important;
  position:static!important;
  float:none!important;
  clear:both!important;
}


/* FINAL RESULT REDESIGN — PraxTools VPS / PHP 8.5 */
.result .excel-hero{padding:18px 0 4px}.result-card{max-width:1120px;padding:clamp(16px,3vw,28px);border-radius:24px;background:rgba(255,255,255,.98)}
.stat-row{justify-content:center;gap:9px}.stat-pill{padding:9px 15px;background:#fff;border-color:#e7e9ef;box-shadow:0 4px 12px rgba(15,23,42,.04)}
.success-box{display:grid;grid-template-columns:auto 1fr;gap:14px;align-items:center;margin:18px 0 20px;padding:18px;border:1px solid #d8eee2;background:#f7fcf9;border-radius:16px;color:#245c42}
.success-box .icon{display:grid;place-items:center;width:42px;height:42px;border-radius:12px;background:#e8f7ee;font-size:22px}.success-box>div{min-width:0;line-height:1.5}
.download-form{margin:12px 0 0}.download-btn{display:inline-flex;align-items:center;justify-content:center;width:auto;min-width:230px;margin:0;border:0;text-decoration:none;appearance:none}
.preview-box{overflow:auto;max-height:58vh;border:1px solid #e5e7eb;border-radius:16px;background:#fff;box-shadow:inset 0 1px 0 rgba(15,23,42,.02)}
.preview-box table{width:max-content;min-width:100%;border-collapse:separate;border-spacing:0;table-layout:auto}.preview-box td{min-width:130px;max-width:360px;padding:11px 13px;border-right:1px solid #edf0f4;border-bottom:1px solid #edf0f4;white-space:pre-wrap;overflow-wrap:anywhere;vertical-align:top;color:#263142}.preview-box tr:first-child td{position:sticky;top:0;z-index:2;background:#f5f7fa!important;color:#111827}.preview-box td:first-child{position:sticky;left:0;z-index:1;background:#fff;font-weight:700}.preview-box tr:first-child td:first-child{z-index:3;background:#f5f7fa!important}.preview-caption{text-align:center;color:#667085;font-size:12px;margin:11px 0 2px}.back-link{display:inline-flex;margin-top:20px;color:#b42336;font-weight:800;text-decoration:none}.back-link:hover{text-decoration:underline}
@media(max-width:700px){.success-box{grid-template-columns:1fr;text-align:center}.success-box .icon{margin:auto}.download-btn{width:100%;min-width:0}.preview-box td{min-width:115px;padding:9px 10px}.result-card{border-radius:18px}}
