/* NOVA COA & QC Panel — screenshot-matched responsive layout */
.nova-coa-panel {
    --nova-coa-ink: #101217;
    --nova-coa-muted: #77808d;
    --nova-coa-line: #e8ebef;
    --nova-coa-green: #20c878;
    display: block;
    width: 100%;
    margin: 24px 0;
    padding: 20px 30px 29px;
    box-sizing: border-box;
    background: #f4f6f8;
    color: #152036;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}
.nova-coa-panel *,
.nova-coa-panel *::before,
.nova-coa-panel *::after { box-sizing: border-box; }
.nova-coa-layout {
    width: 100%;
    display: grid;
    grid-template-columns: minmax(350px, .67fr) minmax(0, 1fr);
    gap: 30px;
    align-items: stretch;
    padding: 0;
    margin: 0 auto;
    background: transparent;
}
.nova-coa-certificate {
    position: relative;
    isolation: isolate;
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 35px 35px 35px;
    border-radius: 22px;
    background: #121214;
    color: #fff;
    box-shadow: none;
}
.nova-coa-certificate::before,
.nova-coa-qc-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #b9dfff 0%, #dbe9ff 65%, #e5f9e9 100%);
    pointer-events: none;
}
.nova-coa-brand-row { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; margin: 0 0 32px; min-height: 44px; }
.nova-coa-monogram { display: grid; place-items: center; flex: 0 0 45px; width: 45px; height: 44px; border-radius: 10px; background: #cce8ff; color: #17263d; font-size: 12px; font-weight: 800; letter-spacing: -.5px; }
.nova-coa-brand-copy { min-width: 0; }
.nova-coa-brand-name { color: #fff; font-size: 20px; line-height: 1.12; font-weight: 750; letter-spacing: -.35px; overflow-wrap: anywhere; }
.nova-coa-brand-subtitle { margin-top: 3px; color: #aab0bb; font-size: 10px; line-height: 1.3; }
.nova-coa-watermark { position: absolute; right: -24px; top: -43px; z-index: -1; color: rgba(255,255,255,.045); font-size: 168px; line-height: 1; font-weight: 900; transform: rotate(-12deg); pointer-events: none; }
.nova-coa-kicker { margin: 0 0 8px; color: #a5abb6; font-size: 11px; font-weight: 750; letter-spacing: 2px; line-height: 1.4; }
.nova-coa-purity-value { color: #fff; font-size: clamp(44px, 4vw, 64px); font-weight: 800; line-height: 1; letter-spacing: -2px; }
.nova-coa-purity-value span { color: #79e99c; font-size: .42em; vertical-align: 12%; margin-left: 3px; letter-spacing: -.5px; }
.nova-coa-purity-label { margin-top: 8px; color: #9da4b0; font-size: 11px; font-weight: 750; letter-spacing: 2px; }
.nova-coa-divider { height: 1px; flex: 0 0 1px; margin: 28px 0 22px; background: rgba(255,255,255,.12); }
.nova-coa-meta-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 22px 20px; }
.nova-coa-meta-item { min-width: 0; display: flex; flex-direction: column; gap: 7px; }
.nova-coa-meta-item span { color: #8e96a4; font-size: 10px; font-weight: 750; letter-spacing: 1.5px; }
.nova-coa-meta-item strong { color: #fff; font-size: 16px; font-weight: 650; line-height: 1.3; overflow-wrap: anywhere; }
.nova-coa-meta-item .nova-coa-measured { color: #79e99c; }
.nova-coa-badges { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 22px; }
.nova-coa-badges span { display: inline-flex; align-items: center; gap: 7px; min-height: 34px; padding: 7px 13px; border: 1px solid rgba(255,255,255,.18); border-radius: 22px; color: #f1f3f6; font-size: 10px; font-weight: 750; line-height: 1.2; letter-spacing: .2px; }
.nova-coa-badges i { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #38d987; }
.nova-coa-pdf-button { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; min-height: 50px; margin-top: auto; padding: 14px 18px; border-radius: 30px; background: #fff; color: #111827 !important; text-decoration: none !important; text-align: center; font-size: 15px; font-weight: 700; line-height: 1.3; transition: background .18s ease, transform .18s ease; }
.nova-coa-pdf-button:hover { background: #eaf4ff; color: #111827 !important; transform: translateY(-1px); }
.nova-coa-pdf-button svg { width: 17px; height: 17px; flex: 0 0 17px; }
.nova-coa-pdf-placeholder { margin-top: auto; padding-top: 16px; color: #9198a4; font-size: 11px; line-height: 1.4; }
.nova-coa-qc-card { position: relative; min-width: 0; min-height: 0; overflow: hidden; border: 1px solid #e0e5ea; border-radius: 22px; background: #fff; color: #142033; }
.nova-coa-qc-header { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 29px; border-bottom: 1px solid var(--nova-coa-line); }
.nova-coa-qc-heading { color: #758092; font-size: 11px; font-weight: 800; letter-spacing: 2px; }
.nova-coa-summary-pill { display: inline-flex; align-items: center; gap: 7px; padding: 8px 13px; border-radius: 24px; background: #e5f7ed; color: #078449; font-size: 11px; font-weight: 750; line-height: 1.2; white-space: nowrap; }
.nova-coa-qc-tests { display: block; }
.nova-coa-qc-row { min-height: 72px; display: grid; grid-template-columns: minmax(145px, 1fr) minmax(95px, auto) 95px; align-items: center; gap: 16px; padding: 14px 29px; border-bottom: 1px solid var(--nova-coa-line); }
.nova-coa-qc-row:last-child { border-bottom: 0; }
.nova-coa-qc-test-name { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.nova-coa-qc-test-name strong { color: #171b22; font-size: 16px; font-weight: 700; line-height: 1.25; overflow-wrap: anywhere; }
.nova-coa-qc-test-name small { color: #8994a4; font-size: 10px; line-height: 1.25; }
.nova-coa-qc-result { color: #18263e; font-size: 14px; line-height: 1.3; text-align: right; overflow-wrap: anywhere; }
.nova-coa-status { min-width: 94px; min-height: 29px; display: inline-flex; align-items: center; justify-content: center; gap: 5px; padding: 7px 10px; border-radius: 20px; font-size: 10px; line-height: 1.1; font-weight: 800; letter-spacing: .3px; white-space: nowrap; }
.nova-coa-status-pass { background: #e4f6ec; color: #078448; }
.nova-coa-status-reported { background: #eff1f4; color: #7b8492; }
.nova-coa-status-fail { background: #ffebeb; color: #b42318; }
.nova-coa-status-pending { background: #fff4d6; color: #8a5b00; }
.nova-coa-empty-tests { padding: 25px 29px; color: #7b8492; font-size: 13px; }
.nova-coa-editor-notice { margin: 14px 0; padding: 12px 14px; border: 1px dashed #a9b7c6; border-radius: 8px; color: #4e5d70; font: 12px/1.5 Arial, sans-serif; }

@media (min-width: 1500px) {
    .nova-coa-panel { padding-top: 24px; padding-bottom: 29px; }
    .nova-coa-certificate { padding: 35px; }
}
@media (max-width: 1100px) {
    .nova-coa-panel { padding: 18px; }
    .nova-coa-layout { grid-template-columns: minmax(300px, .8fr) minmax(0, 1.2fr); gap: 18px; }
    .nova-coa-certificate { min-height: 0; padding: 27px; }
    .nova-coa-qc-card { min-height: 0; }
    .nova-coa-qc-header { padding: 16px 18px; }
    .nova-coa-qc-row { min-height: 65px; grid-template-columns: minmax(110px, 1fr) minmax(65px, auto) 82px; gap: 10px; padding: 11px 18px; }
    .nova-coa-qc-test-name strong { font-size: 14px; }
    .nova-coa-qc-result { font-size: 12px; }
    .nova-coa-status { min-width: 80px; font-size: 9px; }
}
@media (max-width: 900px) {
    .nova-coa-panel { padding: 18px; }
    .nova-coa-layout { grid-template-columns: minmax(0,1fr); gap: 16px; }
    .nova-coa-certificate { min-height: 0; padding: 28px; }
    .nova-coa-qc-card { min-height: 0; }
    .nova-coa-qc-header { min-height: 66px; }
    .nova-coa-qc-row { min-height: 66px; grid-template-columns: minmax(120px, 1fr) minmax(75px, auto) 90px; padding: 12px 20px; }
    .nova-coa-pdf-button { margin-top: 32px; }
}
@media (max-width: 520px) {
    .nova-coa-panel { margin: 18px 0; padding: 12px; }
    .nova-coa-certificate { padding: 22px 19px; border-radius: 16px; }
    .nova-coa-brand-row { margin-bottom: 21px; }
    .nova-coa-brand-name { font-size: 18px; }
    .nova-coa-divider { margin: 23px 0 19px; }
    .nova-coa-meta-grid { gap: 16px 12px; }
    .nova-coa-pdf-button { margin-top: 28px; min-height: 48px; font-size: 13px; }
    .nova-coa-qc-card { border-radius: 16px; }
    .nova-coa-qc-header { align-items: flex-start; flex-direction: column; gap: 10px; padding: 16px; }
    .nova-coa-qc-row { grid-template-columns: minmax(0,1fr) auto; gap: 8px 10px; padding: 13px 15px; }
    .nova-coa-qc-test-name { grid-column: 1; grid-row: 1; }
    .nova-coa-qc-result { grid-column: 1; grid-row: 2; text-align: left; font-size: 12px; }
    .nova-coa-status { grid-column: 2; grid-row: 1 / span 2; min-width: 80px; }
}
