:root{
  --cr-blue:#b88932;
  --cr-blue-dark:#8e6723;
  --cr-text:#171717;
  --cr-muted:#6f6a62;
  --cr-line:#e7e1d7;
  --cr-soft:#f8f6f1;
  --cr-green:#087f5b;
  --cr-green-bg:#e9f8f2;
  --cr-red:#b42318;
  --cr-red-bg:#fff1f0;
  --cr-dark:#151515;
  --cr-dark-2:#24211d;
  --cr-gold:#b88932;
  --cr-gold-soft:#f7f0e2;
}

/* NOVEXIS TESTING INDEX */
.cr-testing-table-wrap{
  width:min(1420px,calc(100% - 48px))!important;
  max-width:none!important;
  margin:0 auto!important;
  padding:58px 0 72px!important;
  color:var(--cr-text);
  font-family:inherit;
  box-sizing:border-box!important;
}
.cr-table-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:32px;margin-bottom:30px}
.cr-table-heading h1{font-size:clamp(32px,3.2vw,46px);line-height:1.05;margin:0;font-weight:700;letter-spacing:-.035em;color:var(--cr-dark)}
.cr-table-heading p{margin:0;max-width:620px;color:var(--cr-muted);font-size:16px;line-height:1.65;text-align:right}
.cr-toolbar{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:14px;align-items:center;margin-bottom:0}
.cr-toolbar,.cr-toolbar *{box-sizing:border-box!important}
.cr-search-wrap{position:relative;min-width:0!important}
.cr-search-wrap input,.cr-select-form select{
  width:100%!important;height:56px!important;border:1px solid var(--cr-line)!important;border-radius:3px!important;
  background:#fff!important;color:var(--cr-text)!important;font-size:15px!important;box-shadow:none!important;max-width:100%!important;
}
.cr-search-wrap input{padding:0 18px 0 50px!important}
.cr-search-wrap input:focus,.cr-select-form select:focus{border-color:var(--cr-gold)!important;box-shadow:0 0 0 3px rgba(184,137,50,.10)!important;outline:0!important}
.cr-search-icon{position:absolute;left:18px;top:50%;transform:translateY(-53%);font-size:26px;line-height:1;color:#a39b90;pointer-events:none}
.cr-select-form{margin:0!important;min-width:0!important;width:100%!important}.cr-select-form select{padding:0 42px 0 16px!important}
.cr-result-count{margin:20px 0 15px;color:var(--cr-muted);font-size:14px}.cr-result-count strong{color:var(--cr-dark)}
.cr-table-shell{width:100%!important;border:1px solid var(--cr-line);border-radius:4px;background:#fff;overflow:hidden;box-sizing:border-box!important;box-shadow:0 10px 35px rgba(30,25,20,.035)}
.cr-table-scroll{width:100%;overflow-x:auto!important;max-width:100%!important}
.cr-results-table{width:100%!important;min-width:1120px!important;border-collapse:separate;border-spacing:0;margin:0!important;background:#fff;table-layout:auto!important}
.cr-results-table th,.cr-results-table td{padding:16px 13px!important;border:0!important;border-bottom:1px solid #eee9e2!important;text-align:left;vertical-align:middle;white-space:nowrap;font-size:13px!important}
.cr-results-table th{background:#f8f6f2;color:#6f685e;font-size:11.5px!important;font-weight:700;letter-spacing:.055em;text-transform:uppercase;white-space:normal!important;line-height:1.2!important}
.cr-results-table tbody tr:last-child td{border-bottom:0!important}.cr-results-table tbody tr:hover td{background:#fcfaf6}
.cr-product-cell a,.cr-coa-view{color:#1e1c19!important;text-decoration:none!important;font-weight:700}.cr-product-cell a:hover,.cr-coa-view:hover{color:var(--cr-gold)!important}
.cr-batch-cell{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;color:#4c4439}
.cr-mass-pill{display:inline-flex;padding:5px 10px;border-radius:999px;background:#f2efe9;font-weight:700;color:#26231f}
.cr-purity-pill,.cr-pill{display:inline-flex;align-items:center;justify-content:center;padding:4px 10px;border-radius:999px;font-weight:750;line-height:1.2}
.cr-purity-pill,.cr-pill-pass{background:var(--cr-green-bg);border:1px solid #b9e8d7;color:var(--cr-green)}
.cr-pill-fail{background:var(--cr-red-bg);border:1px solid #f1c2bc;color:var(--cr-red)}
.cr-pill-na{background:#f3f1ed;border:1px solid #e5e0d8;color:#777168}
.cr-coa-view{display:inline-flex;gap:6px;align-items:center}.cr-no-results-row td{text-align:center!important;padding:52px 20px!important;color:var(--cr-muted)}
.cr-testing-note{margin:18px 0 0;color:var(--cr-muted);font-size:13px;line-height:1.55}.cr-built-by{display:none!important}

/* PRODUCT PAGE COA CTA */
.cr-product-testing{margin:15px 0 20px}
.cr-product-coa-btn{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:9px!important;min-height:50px!important;padding:0 22px!important;
  border-radius:2px!important;border:1px solid var(--cr-gold)!important;background:#fff!important;color:var(--cr-dark)!important;font-weight:700!important;
  text-transform:none!important;letter-spacing:.01em!important;box-shadow:none!important;transition:.2s ease!important
}
.cr-product-coa-btn:hover{background:var(--cr-dark)!important;border-color:var(--cr-dark)!important;color:#fff!important}.cr-doc-icon{font-size:17px}

/* BATCH DETAIL: isolate from theme widths */
.cr-coa-batch-view .page-title,.cr-coa-batch-view .title-wrapper,.cr-coa-batch-view .page-title-default,.cr-coa-batch-view .wd-page-title,.cr-coa-batch-view .breadcrumbs-wrapper{display:none!important}
.cr-coa-batch-view .site-content,.cr-coa-batch-view .main-page-wrapper,.cr-coa-batch-view .container,.cr-coa-batch-view .content-layout-wrapper,.cr-coa-batch-view #content,.cr-coa-batch-view .content-area{
  max-width:none!important;width:100%!important;padding-left:0!important;padding-right:0!important;margin-left:0!important;margin-right:0!important
}
.cr-batch-page{width:100%!important;max-width:none!important;margin:0!important;background:#f8f6f1;min-height:70vh;overflow:hidden;color:var(--cr-text)}
.cr-batch-hero{background:linear-gradient(135deg,#111 0%,#1e1c19 58%,#31291b 100%);color:#fff;padding:52px 0 56px;position:relative;overflow:hidden}
.cr-batch-hero:after{content:"";position:absolute;right:-120px;top:-220px;width:520px;height:520px;border-radius:50%;background:radial-gradient(circle,rgba(184,137,50,.34),rgba(184,137,50,0) 68%)}
.cr-batch-hero-inner{width:min(1180px,calc(100% - 48px));margin:0 auto;position:relative;z-index:1}
.cr-back{display:inline-flex;color:#e8dcc4!important;text-decoration:none!important;font-weight:650;margin:0 0 32px;font-size:14px}.cr-back:hover{color:#fff!important}
.cr-batch-title-row{display:flex;align-items:center;justify-content:space-between;gap:40px}.cr-eyebrow{font-size:11px;text-transform:uppercase;letter-spacing:.17em;color:#d2b77c;font-weight:800}
.cr-batch-hero h1{margin:9px 0 11px;color:#fff;font-size:clamp(36px,4.2vw,58px);letter-spacing:-.04em;line-height:1.02;font-weight:700}
.cr-batch-subline{display:flex;align-items:center;gap:12px;flex-wrap:wrap;color:#d3cdc4;font-size:15px}.cr-status-approved{display:inline-flex;align-items:center;padding:5px 11px;border-radius:999px;background:#e9f8f2;color:#087f5b;font-weight:800;font-size:12px}
.cr-batch-image{flex:0 0 176px;width:176px;height:176px;border-radius:8px;background:#fff;display:flex;align-items:center;justify-content:center;padding:14px;box-shadow:0 22px 60px rgba(0,0,0,.24)}
.cr-batch-image img{width:100%;height:100%;object-fit:contain;border-radius:4px}
.cr-batch-wrap{width:min(1180px,calc(100% - 48px));max-width:none!important;margin:0 auto!important;padding:36px 0 72px!important;box-sizing:border-box}
.cr-summary-card{background:#fff;border:1px solid var(--cr-line);border-radius:4px;padding:22px;box-shadow:0 10px 35px rgba(30,25,20,.04)}
.cr-detail-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin:0}.cr-detail-grid>div{background:#faf8f4;border:1px solid #ece6dc;border-radius:3px;padding:16px;min-width:0}
.cr-detail-grid span{display:block;font-size:10.5px;color:#7c7469;font-weight:750;margin-bottom:6px;text-transform:uppercase;letter-spacing:.07em}.cr-detail-grid strong{font-size:15px;word-break:break-word;color:#211e1a}.cr-green-value{color:#087f5b!important}
.cr-pass-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:12px 0 0}.cr-pass-grid>div{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 16px;background:#faf8f4;border:1px solid #ece6dc;border-radius:3px;font-weight:700}.cr-pass-grid>div>span:first-child{color:#514b43}
.cr-coa-section{margin-top:32px;background:#fff;border:1px solid var(--cr-line);border-radius:4px;padding:26px;box-shadow:0 10px 35px rgba(30,25,20,.04)}
.cr-section-head{display:flex;justify-content:space-between;align-items:flex-end;gap:30px;margin-bottom:20px}.cr-section-head h2{margin:5px 0 0;font-size:30px;color:#1a1815}.cr-section-head p{margin:0;color:var(--cr-muted);font-size:14px}
.cr-coa-pages{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}.cr-coa-pages a{text-decoration:none!important;color:var(--cr-text)!important;border:1px solid var(--cr-line);border-radius:3px;padding:10px;background:#fbfaf7;transition:.2s ease}.cr-coa-pages a:hover{transform:translateY(-2px);box-shadow:0 12px 30px rgba(30,25,20,.08);border-color:#d8c7a6}
.cr-coa-pages img{display:block;width:100%;max-height:760px;object-fit:contain;object-position:top;background:#fff;border:0;border-radius:2px}.cr-coa-pages span{display:block;text-align:center;margin:10px 0 2px;font-size:12px;font-weight:700;color:var(--cr-gold)}
.cr-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:22px}.cr-primary,.cr-secondary{display:inline-flex;align-items:center;justify-content:center;min-height:48px;padding:0 18px;border-radius:2px;text-decoration:none!important;font-weight:700}
.cr-primary{background:var(--cr-dark);color:#fff!important;border:1px solid var(--cr-dark)}.cr-primary:hover{background:var(--cr-gold)!important;border-color:var(--cr-gold)!important;color:#fff!important}
.cr-secondary{background:#fff;color:#28231c!important;border:1px solid #d8d0c5}.cr-secondary:hover{border-color:var(--cr-gold);color:var(--cr-gold)!important}.cr-notes{margin-top:18px;padding:16px;border-radius:3px;background:#fff;border:1px solid var(--cr-line)}
.cr-product-directory,.cr-product-tile{display:none!important}

@media(min-width:1200px){.cr-table-scroll{overflow-x:visible!important}.cr-results-table{min-width:0!important}}
@media(max-width:1050px){.cr-detail-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:900px){.cr-testing-table-wrap{width:min(100% - 28px,1420px)!important;padding:38px 0 56px!important}.cr-table-heading{display:block}.cr-table-heading p{text-align:left;margin-top:10px}.cr-toolbar{grid-template-columns:1fr}.cr-detail-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.cr-pass-grid{grid-template-columns:1fr}.cr-coa-pages{grid-template-columns:1fr}}
@media(max-width:760px){.cr-batch-hero-inner,.cr-batch-wrap{width:min(100% - 28px,1180px)}.cr-batch-title-row{align-items:flex-start}.cr-batch-image{width:120px;height:120px;flex-basis:120px}.cr-section-head{display:block}.cr-section-head p{margin-top:8px}}
@media(max-width:520px){.cr-testing-table-wrap{padding-top:30px!important}.cr-table-heading h1{font-size:30px}.cr-batch-title-row{display:block}.cr-batch-image{margin-top:22px}.cr-detail-grid{grid-template-columns:1fr}.cr-coa-section{padding:18px}}

/* v2.1: force batch detail to escape WoodMart's opened content container */
body.cr-coa-batch-view{overflow-x:hidden!important}
body.cr-coa-batch-view .cr-batch-page{
  position:relative!important;
  width:100vw!important;
  max-width:100vw!important;
  min-width:100vw!important;
  flex:0 0 100vw!important;
  left:50%!important;
  margin-left:-50vw!important;
  margin-right:-50vw!important;
  box-sizing:border-box!important;
  clear:both!important;
}
body.cr-coa-batch-view .cr-batch-hero,
body.cr-coa-batch-view .cr-batch-wrap{box-sizing:border-box!important}
body.cr-coa-batch-view .cr-batch-hero-inner,
body.cr-coa-batch-view .cr-batch-wrap{
  width:min(1180px,calc(100vw - 48px))!important;
  max-width:1180px!important;
  margin-left:auto!important;
  margin-right:auto!important;
}

/* v2.1: dynamic COA CTA beside WooCommerce Add to Cart */
.cr-coa-cta-row{
  display:flex!important;
  align-items:center!important;
  gap:12px!important;
  flex-wrap:wrap!important;
}
.cr-coa-cta-row .cr-product-testing-fallback{
  display:block;
  margin:0!important;
  flex:0 0 auto!important;
}
.cr-coa-cta-row .cr-product-coa-btn{
  min-height:48px!important;
  padding:0 22px!important;
  white-space:nowrap!important;
  border-color:#c9962d!important;
  color:#171717!important;
  background:#fff!important;
}
.cr-coa-cta-row .cr-product-coa-btn:hover{
  background:#171717!important;
  border-color:#171717!important;
  color:#fff!important;
}
@media(max-width:767px){
  body.cr-coa-batch-view .cr-batch-hero-inner,
  body.cr-coa-batch-view .cr-batch-wrap{width:calc(100vw - 28px)!important}
  .cr-coa-cta-row{gap:9px!important}
}

/* v2.1.2: COA table links open the uploaded PDF directly */
.cr-coa-view{display:inline-flex;align-items:center;gap:6px;white-space:nowrap}
.cr-coa-view .cr-doc-icon{display:block;flex:0 0 auto}
.cr-coa-disabled{opacity:.45;cursor:not-allowed;text-decoration:none!important}
