:root{font-family:system-ui,-apple-system,"Segoe UI",Arial,sans-serif;color:#243746;background:#f1f6fa}*{box-sizing:border-box}
.pdf9-page{margin:0}.pdf9-top{position:sticky;top:0;z-index:12;display:flex;justify-content:space-between;gap:16px;align-items:center;background:#173d5d;color:#fff;padding:12px clamp(12px,3vw,32px);box-shadow:0 2px 8px #163b6030}.pdf9-top-left{display:flex;align-items:center;gap:20px;flex-wrap:wrap}.pdf9-top-left a{color:#e5f5ff;text-underline-offset:3px}.pdf9-top strong{font-size:17px}button,input,select{font:inherit}button{cursor:pointer;min-height:42px;border:0;border-radius:9px;padding:9px 15px;font-size:14px;font-weight:700}button:disabled{opacity:.55;cursor:not-allowed}.pdf9-top button,#pdf9-print-2{background:#fff;color:#164f70}.pdf9-layout{display:grid;grid-template-columns:minmax(390px,42%) minmax(0,1fr);gap:22px;align-items:start;max-width:1620px;margin:auto;padding:20px}.pdf9-controls,.pdf9-preview{min-width:0;background:#fff;border:1px solid #dae5ec;border-radius:16px;box-shadow:0 5px 25px #123c5510}.pdf9-controls{padding:24px;max-height:none}.pdf9-controls h1{font-size:24px;line-height:1.25;margin:0 0 8px;color:#193e59}.pdf9-muted{margin:0 0 20px;color:#516577;line-height:1.5}.pdf9-grid2,.pdf9-grid3{display:grid;gap:12px}.pdf9-grid2{grid-template-columns:repeat(2,minmax(0,1fr));margin:14px 0}.pdf9-grid3{grid-template-columns:repeat(3,minmax(0,1fr))}.pdf9-controls label>span{display:block;font-size:13px;font-weight:700;margin-bottom:6px;color:#37566e}.pdf9-controls label small{font-size:11px;color:#73889a;font-weight:500}.pdf9-controls input:not([type=checkbox]),.pdf9-controls select{width:100%;min-width:0;min-height:43px;background:white;border:1px solid #bdcdd8;border-radius:9px;padding:8px 10px;color:#173e5a;font-size:14px}.pdf9-quotas{border:1px solid #d6e5ee;border-radius:13px;padding:15px 13px;margin:18px 0;background:#f7fbfe}.pdf9-quotas legend{font-weight:800;color:#1c5072;padding:0 7px}.pdf9-row{display:flex;gap:8px;flex-wrap:wrap;margin:14px 0 5px}.pdf9-action{background:#135d8e;color:#fff}.pdf9-action:hover{background:#0d496f}.pdf9-secondary{background:#e6f0f6;color:#20536e}.pdf9-bulk{display:flex;align-items:flex-end;gap:10px;flex-wrap:wrap;margin-top:12px}.pdf9-bulk label{min-width:165px;flex:1}.pdf9-bulk button{margin-bottom:0}.pdf9-hint{font-size:12px;color:#63788a;margin:10px 0 0;line-height:1.55}.pdf9-toggles{display:flex;flex-wrap:wrap;gap:15px;margin:12px 0}.pdf9-toggles label{font-size:13px;color:#3d566a}.pdf9-toggles input{accent-color:#1b6594}.pdf9-picker-top{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:20px}.pdf9-picker-top h2{font-size:18px;color:#214764;margin:0}.pdf9-picker-top input{max-width:210px}.pdf9-counters{color:#486b82;font-size:13px;font-weight:700;margin:12px 0}.pdf9-question-list{max-height:560px;overflow-y:auto;border:1px solid #d7e2eb;border-radius:12px}.pdf9-pick-row{display:grid;grid-template-columns:22px minmax(0,1fr) 122px;align-items:start;gap:10px;padding:12px 10px;border-bottom:1px solid #e7edf2}.pdf9-pick-row:last-child{border:0}.pdf9-pick-row.is-picked{background:#f3f9fd}.pdf9-pick-row input[type=checkbox]{width:18px;height:18px;margin:5px 0 0;accent-color:#155d89}.pdf9-pick-detail{min-width:0}.pdf9-item-title{display:block;color:#214e70;font-size:13px;margin-bottom:3px}.pdf9-item-snippet{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;font-size:12px;line-height:1.5;color:#617285}.pdf9-level-select{font-size:12px!important;min-height:36px!important;padding:6px 4px!important}.pdf9-level-select.not-classified{background:#fff8e9!important;border-color:#e6c58b!important}.pdf9-level-note{font-size:10px;color:#627c8c}.pdf9-message{border-top:1px solid #e3eaf0;padding:12px 0 0;margin:14px 0;font-size:13px;color:#315775;line-height:1.5}.pdf9-actions-bottom{display:flex;gap:10px;flex-wrap:wrap}.pdf9-preview{padding:0;overflow:hidden}.pdf9-preview-head{display:flex;align-items:center;gap:10px;justify-content:space-between;background:#f6fafc;padding:13px 18px;border-bottom:1px solid #e0e9f0;font-size:13px;color:#4a6b82}.pdf9-preview-head strong{font-size:15px;color:#1b4a6b}.pdf9-paper{background:#fff;color:#111;padding:16mm 13mm;margin:18px auto;width:min(calc(100% - 28px),210mm);min-height:297mm;box-shadow:0 3px 20px #163b5124;font-family:"Times New Roman",Times,serif;line-height:1.45;font-size:var(--pdf9-font,12pt);overflow-wrap:break-word}.pdf9-placeholder{font-family:system-ui,sans-serif;color:#718396;font-size:14px}.pdf9-sheet-head{text-align:center;border-bottom:1px solid #aebbc4;padding-bottom:8mm;margin:0 0 8mm}.pdf9-brand{font-family:Arial,sans-serif;font-size:10pt;letter-spacing:.06em;font-weight:800;color:#173f5b}.pdf9-sheet-head h2{font-size:16pt;line-height:1.3;color:#111;margin:6mm 0 2mm}.pdf9-sheet-meta,.pdf9-name{font-size:10pt;margin:3mm 0}.pdf9-name{text-align:left;padding-top:4mm}.pdf9-sheet-question{break-inside:auto;margin:0 0 7mm}.pdf9-sheet-question.pdf9-keep{break-inside:avoid;page-break-inside:avoid}.pdf9-sheet-question h3{break-after:avoid;margin:0 0 3mm;font:700 12.5pt/1.4 "Times New Roman",Times,serif}.pdf9-sheet-intro{break-after:avoid;margin:0 0 3mm}.pdf9-sheet-parts{display:grid;grid-template-columns:minmax(0,1fr);gap:5mm 7mm;align-items:start}.pdf9-sheet-parts.cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.pdf9-sheet-parts.cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.pdf9-sheet-part{min-width:0;break-inside:avoid;page-break-inside:avoid}.pdf9-sheet-part:has(img),.pdf9-sheet-part:has(table),.pdf9-sheet-part:has(svg:not(mjx-container svg)){break-inside:auto}.pdf9-sheet-part h4{margin:0 0 1.5mm;font-size:1em;font-weight:700}.pdf9-sheet-level{font-size:8pt;color:#6e7b83;border:1px solid #bac6ce;padding:1px 4px;border-radius:3px;display:inline-block;margin-bottom:1mm}.pdf9-rich{max-width:100%;overflow-wrap:break-word}.pdf9-rich p{margin:0 0 2mm;line-height:1.45}.pdf9-rich p:last-child{margin-bottom:0}.pdf9-rich :is(ol,ul){padding-left:5mm;margin:2mm 0}.pdf9-rich :is(img,svg:not(mjx-container svg)){display:block;max-width:100%!important;width:auto;height:auto;max-height:180mm;object-fit:contain;margin:3mm auto}.pdf9-rich figure{margin:3mm 0;text-align:center}.pdf9-rich figcaption{font-size:9pt}.pdf9-rich table{border-collapse:collapse;max-width:100%;width:100%;font-size:.87em}.pdf9-rich :is(td,th){border:1px solid #999;padding:3px 5px}.pdf9-rich mjx-container[display="true"]{max-width:100%;overflow:visible}.pdf9-answer-space{margin-top:3mm}.pdf9-answer-line{height:5.8mm;border-bottom:.4pt dotted #96a5b1;break-inside:avoid;page-break-inside:avoid}.pdf9-sheet-foot{font-family:Arial,sans-serif;font-size:8pt;color:#69757e;border-top:1px solid #d8e0e5;padding-top:3mm;margin-top:10mm;overflow-wrap:anywhere}
@media(max-width:1180px){.pdf9-layout{grid-template-columns:minmax(310px,43%) minmax(0,1fr);padding:12px;gap:12px}.pdf9-controls{padding:16px}.pdf9-paper{padding:12mm 8mm}}
@media(max-width:850px){.pdf9-layout{grid-template-columns:1fr}.pdf9-paper{width:min(100%,210mm);padding:12mm;box-shadow:none;margin:0 auto}.pdf9-preview{margin-bottom:18px}.pdf9-top{position:static}.pdf9-question-list{max-height:460px}}
@media(max-width:520px){.pdf9-top strong{font-size:14px}.pdf9-layout{padding:8px}.pdf9-grid2{grid-template-columns:1fr}.pdf9-grid3{gap:7px}.pdf9-grid3 input{padding:8px 5px!important}.pdf9-picker-top{align-items:stretch;flex-direction:column}.pdf9-picker-top input{max-width:none}.pdf9-pick-row{grid-template-columns:22px minmax(0,1fr) 110px;padding:10px 7px;gap:6px}.pdf9-paper{font-size:10pt;padding:12px}.pdf9-sheet-parts.cols-3{grid-template-columns:repeat(2,minmax(0,1fr))}}
@page{size:A4 portrait;margin:13mm 12mm 15mm}
@media print{
 html,body{background:white!important;margin:0!important;padding:0!important;color:#000!important}
 .pdf9-top,.pdf9-controls,.pdf9-preview-head{display:none!important}
 .pdf9-layout,.pdf9-preview{display:block!important;max-width:none!important;width:100%!important;margin:0!important;padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important}
 .pdf9-paper{width:100%!important;max-width:none!important;min-height:0!important;box-shadow:none!important;border:0!important;padding:0!important;margin:0!important;overflow:visible!important;font-size:var(--pdf9-font,12pt)!important;line-height:1.42}
 .pdf9-sheet-head h2{font-size:16pt}.pdf9-sheet-question{break-inside:auto;page-break-inside:auto}
 .pdf9-sheet-question.pdf9-keep{break-inside:avoid!important;page-break-inside:avoid!important}
 .pdf9-sheet-part{break-inside:avoid;page-break-inside:avoid}
 .pdf9-sheet-parts.cols-2{grid-template-columns:repeat(2,minmax(0,1fr))!important}
 .pdf9-sheet-parts.cols-3{grid-template-columns:repeat(3,minmax(0,1fr))!important}
 .pdf9-sheet-part:has(img),.pdf9-sheet-part:has(table),.pdf9-sheet-part:has(svg:not(mjx-container svg)){break-inside:auto}
 .pdf9-rich mjx-container{overflow:visible!important}.pdf9-rich mjx-container svg{max-width:100%!important;height:auto!important}
 .pdf9-rich :is(img,svg:not(mjx-container svg)){max-width:100%!important;height:auto!important;max-height:180mm!important}
 .pdf9-not-ready .pdf9-paper{display:none!important}.pdf9-not-ready .pdf9-preview::before{content:'Đề chưa sẵn sàng. Vui lòng đóng hộp thoại in và kiểm tra câu hỏi, công thức và hình.';font:14pt Arial,sans-serif;display:block;padding:20mm 10mm}
}
/* 41.8: one measured A4 layout for screen and print, including fixed 1–3 columns. */
.pdf9-paper{width:210mm;padding:13mm 12mm 15mm;font-size:var(--pdf9-font,12pt)}
.pdf9-paper.pdf9-paginated{width:100%;padding:8px;margin:0;min-height:0;background:#e9f0f5;box-shadow:none;position:relative;overflow:hidden}
.pdf9-pages{width:210mm;transform-origin:top left;margin:0 auto;color:#111;font-size:var(--pdf9-font,12pt);line-height:1.45}
.pdf9-a4-sheet{width:210mm;height:297mm;padding:13mm 12mm 15mm;background:#fff;display:flex;flex-direction:column;gap:4mm;margin:0 0 16px;box-shadow:0 2px 12px #193b4920;overflow:visible}
.pdf9-a4-sheet .pdf9-sheet-head{flex:none;margin:0;padding-bottom:4mm}
.pdf9-a4-sheet .pdf9-sheet-head h2{margin:3mm 0 2mm;font-size:15pt}
.pdf9-page-columns{display:grid;grid-template-columns:repeat(var(--pdf9-columns),minmax(0,1fr));column-gap:7mm;flex:1;min-height:0}
.pdf9-page-column{height:100%;min-height:0;min-width:0}
.pdf9-a4-sheet .pdf9-sheet-question{margin:0 0 5mm;break-inside:avoid}
.pdf9-a4-sheet .pdf9-sheet-question h3{font-size:1.04em;margin:0 0 2mm}
.pdf9-a4-sheet .pdf9-sheet-parts,.pdf9-a4-sheet .pdf9-sheet-parts.cols-1{display:block}
.pdf9-a4-sheet .pdf9-sheet-part{margin:0 0 4mm}
.pdf9-page-number{flex:none;text-align:center;border-top:1px solid #d8e0e5;padding-top:2mm;font:8pt Arial,sans-serif;color:#69757e}
@media print{
 @page{size:A4 portrait;margin:0}
 .pdf9-paper.pdf9-paginated{height:auto!important;padding:0!important;margin:0!important;width:auto!important;overflow:visible!important;background:white!important}
 .pdf9-pages{transform:none!important;margin:0!important;width:210mm!important}
 .pdf9-a4-sheet{width:210mm!important;height:297mm!important;margin:0!important;padding:13mm 12mm 15mm!important;box-shadow:none!important;break-after:page!important;page-break-after:always!important;break-inside:avoid!important}
 .pdf9-a4-sheet:last-child{break-after:auto!important;page-break-after:auto!important}
 .pdf9-page-columns{display:grid!important}
 .pdf9-a4-sheet .pdf9-sheet-parts{display:block!important}
}

.pdf9-file{display:inline-flex;align-items:center;padding:10px 14px;border:2px solid #135d8e;border-radius:9px;color:#135d8e;background:#fff;font:700 14px system-ui,sans-serif;text-decoration:none}
/* 41.14: simple default, progressive options and touch targets. Print rules above stay intact. */
@media screen {
 .pdf9-simple [hidden]{display:none!important}
 .pdf9-simple .pdf9-top{position:static;min-height:64px;box-shadow:none}
 .pdf9-simple .pdf9-top a{color:#fff;text-decoration:none;font-size:15px}
 .pdf9-simple .pdf9-top strong{font-size:16px}
 .pdf9-simple .pdf9-layout{display:block;max-width:740px;padding:24px 16px 40px}
 .pdf9-simple .pdf9-layout.has-preview{display:grid;grid-template-columns:minmax(340px,40%) minmax(0,1fr);max-width:1500px;gap:20px}
 .pdf9-simple .pdf9-controls{padding:28px;border-radius:18px;box-shadow:0 5px 24px #163d5510}
 .pdf9-simple h1{font-size:30px;margin-bottom:12px}
 .pdf9-exam-title{font-size:17px;font-weight:650;line-height:1.5;margin:0 0 8px;color:#214761;overflow-wrap:anywhere}
 .pdf9-simple .pdf9-muted{font-size:15px;margin-bottom:24px}
 .pdf9-presets{padding:0;margin:0 0 20px;border:0;min-width:0}
 .pdf9-presets legend{font-weight:700;font-size:14px;margin-bottom:10px}
 .pdf9-preset-options{display:grid;grid-template-columns:1fr 1fr;gap:12px}
 .pdf9-preset-options label{display:flex;align-items:center;gap:10px;border:1px solid #c4d5e0;border-radius:12px;padding:16px 12px;cursor:pointer;background:#fff;min-height:80px}
 .pdf9-preset-options label:has(input:checked){border:2px solid #17618c;padding:15px 11px;background:#f0f8fd}
 .pdf9-simple .pdf9-preset-options input{width:18px;height:18px;min-height:0;flex:none;accent-color:#155f8e;margin:0;padding:0}
 .pdf9-simple .pdf9-preset-options label>span{font-size:15px;line-height:1.35;margin:0}
 .pdf9-preset-options small{display:block;font-size:12px!important;font-weight:400;color:#60798a;margin-top:5px}
 .pdf9-disclosure{border:1px solid #d8e3eb;border-radius:12px;margin-top:12px;overflow:hidden}
 .pdf9-disclosure>summary{display:flex;align-items:center;justify-content:space-between;gap:12px;cursor:pointer;list-style:none;padding:17px 16px;min-height:58px;font-size:15px;font-weight:650}
 .pdf9-disclosure>summary::-webkit-details-marker{display:none}
 .pdf9-disclosure>summary::after{content:'＋';font-size:19px;font-weight:400;flex:none;color:#366783}
 .pdf9-disclosure[open]>summary::after{content:'−'}
 .pdf9-disclosure>summary small{font-size:12px;font-weight:400;color:#5c7485;flex:1;text-align:right}
 .pdf9-disclosure[open]>summary{background:#f4f8fb;border-bottom:1px solid #dfe9f0}
 .pdf9-disclosure-body{padding:14px}
 .pdf9-disclosure-body a{display:inline-block;color:#155f8e;font-size:14px;padding:10px 0}
 .pdf9-simple button{min-height:44px;font-size:14px}
 .pdf9-simple input:not([type=checkbox]):not([type=radio]),.pdf9-simple select{font-size:16px;min-height:44px}
 .pdf9-selection-tools{display:flex;align-items:flex-end;flex-wrap:wrap;gap:8px}
 .pdf9-selection-tools>label{flex:1;min-width:160px}
 .pdf9-selection-tools>button{font-size:13px}
 .pdf9-subdisclosure{margin-top:16px;font-size:14px}
 .pdf9-subdisclosure>summary{cursor:pointer;padding:10px 0;min-height:44px;color:#255c7c}
 .pdf9-simple .pdf9-quotas{margin:8px 0 14px;padding:12px 10px}
 .pdf9-quotas>button{margin-top:12px}
 .pdf9-simple .pdf9-picker-top{display:flex;flex-wrap:wrap;align-items:center;gap:12px;margin-top:16px}
 .pdf9-simple .pdf9-picker-top>input{max-width:none;flex:1;min-width:170px}
 .pdf9-selected-filter{font-size:13px;display:flex;align-items:center;gap:5px;min-height:44px;cursor:pointer}
 .pdf9-selected-filter input{width:18px;height:18px;accent-color:#155f8e}
 .pdf9-simple .pdf9-counters{font-size:13px;font-weight:500}
 .pdf9-simple .pdf9-question-list{max-height:none;overflow:visible}
 .pdf9-simple .pdf9-pick-row{display:block;padding:10px 12px}
 .pdf9-pick-label{display:flex;gap:12px;align-items:flex-start;cursor:pointer;min-height:44px;padding:4px 0}
 .pdf9-simple .pdf9-pick-label input{width:20px;height:20px;flex:none;margin:2px 0 0}
 .pdf9-simple .pdf9-item-title{font-size:14px;margin:0 0 4px}
 .pdf9-simple .pdf9-item-snippet{font-size:13px;font-weight:400;margin:0;color:#60758a}
 .pdf9-simple .pdf9-level-box{display:none;margin:5px 0 8px 32px}
 .pdf9-simple .show-levels .pdf9-level-box{display:block}
 .pdf9-simple .pdf9-level-select{font-size:14px!important}
 .pdf9-question-detail{margin-left:32px;font-size:14px}
 .pdf9-question-detail>summary{cursor:pointer;color:#366c8b;padding:6px 0;min-height:32px;font-size:12px}
 .pdf9-question-detail .pdf9-rich{padding:8px 0;line-height:1.6;color:#223d50;overflow-x:auto}
 .pdf9-question-detail .pdf9-rich>strong{display:block;margin-top:10px}
 .pdf9-pager{display:flex;justify-content:space-between;align-items:center;gap:8px;margin:12px 0;font-size:12px;color:#5a7385}
 .pdf9-pager button{padding:9px 12px;font-size:12px}
 .pdf9-simple .pdf9-message{border:0;font-size:14px;min-height:24px;margin:18px 0 14px;padding:0}
 .pdf9-simple .pdf9-actions-bottom{display:grid;grid-template-columns:1.5fr 1fr auto;gap:8px;background:#fff}
 .pdf9-simple .pdf9-actions-bottom button{min-height:50px}
 .pdf9-simple #pdf9-print-2{background:#edf3f7;color:#20536e}
 .pdf9-simple .pdf9-file{margin-top:12px;font-size:14px}
 .pdf9-simple .pdf9-preview{scroll-margin-top:20px;min-width:0}
 .pdf9-simple .pdf9-paper{max-width:none}
 .pdf9-simple .pdf9-paper:not(.pdf9-paginated){position:absolute;left:-10000px;visibility:hidden}
 .pdf9-simple .pdf9-preview-head{padding:10px 14px}
 .pdf9-simple .pdf9-preview-head button{min-height:36px;font-size:12px;padding:6px 12px}
 .pdf9-simple :is(button,input,select,a,summary):focus-visible{outline:3px solid #edb851;outline-offset:3px}
 @media(max-width:850px){
  .pdf9-simple .pdf9-layout.has-preview{display:block;max-width:740px}
  .pdf9-simple .pdf9-preview{margin-top:16px}
 }
 @media(max-width:520px){
  .pdf9-simple .pdf9-top{padding:14px 16px;gap:10px;min-height:58px}
  .pdf9-simple .pdf9-top strong{font-size:14px}
  .pdf9-simple .pdf9-layout{padding:14px 10px 24px}
  .pdf9-simple .pdf9-controls{padding:20px 16px}
  .pdf9-simple h1{font-size:26px}
  .pdf9-exam-title{font-size:16px}
  .pdf9-simple .pdf9-muted{font-size:14px}
  .pdf9-preset-options{gap:8px}
  .pdf9-preset-options label{padding:12px 9px;gap:7px}
  .pdf9-preset-options label:has(input:checked){padding:11px 8px}
  .pdf9-simple .pdf9-preset-options label>span{font-size:14px}
  .pdf9-disclosure>summary{flex-wrap:wrap;padding:14px 12px;gap:6px;font-size:14px}
  .pdf9-disclosure>summary small{font-size:11px}
  .pdf9-disclosure-body{padding:12px 10px}
  .pdf9-simple .pdf9-actions-bottom{position:sticky;bottom:0;padding:12px 0 calc(8px + env(safe-area-inset-bottom));z-index:3;border-top:1px solid #e1eaf0}
  .pdf9-simple .pdf9-actions-bottom button{font-size:13px;padding:10px 8px}
  .pdf9-simple .pdf9-picker-top{flex-direction:row}
  .pdf9-simple .pdf9-grid2{grid-template-columns:1fr 1fr}
  .pdf9-simple .pdf9-toggles{display:grid;gap:12px}
  .pdf9-simple .pdf9-toggles label{min-height:32px;display:flex;align-items:center;gap:8px}
 }
}

/* Work spacing: real ruled rows survive both PDF raster export and print. */
.pdf9-answer-line{height:7mm;min-height:7mm;border-bottom:.5pt dotted #8595a1}
.pdf9-answer-continuation{margin:0 0 7mm}.pdf9-answer-continuation h3{font:700 11pt/1.4 "Times New Roman",serif;margin:0 0 3mm}
.pdf9-work-options{padding:12px 14px;margin:-4px 0 18px;background:#f0f7fb;border-radius:12px}
.pdf9-work-options[hidden]{display:none}.pdf9-work-options>label{display:flex;align-items:center;gap:12px}.pdf9-work-options>label>span{flex-shrink:0;margin:0}.pdf9-work-options select{flex:1}
.pdf9-work-edit{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin:12px 0 20px;padding:10px;background:#f0f7fb;border-radius:8px}.pdf9-work-edit select{flex:1;min-width:180px!important}.pdf9-work-edit>span{margin:0!important}
@media(max-width:520px){.pdf9-work-options>label{align-items:flex-start;flex-direction:column;gap:4px}.pdf9-work-options select{width:100%}}

/* 41.20: one true/false block, compact branded masthead, measured writing space. */
.pdf9-masthead{display:grid;grid-template-columns:26mm minmax(0,1fr) 26mm;gap:4mm;align-items:center}
.pdf9-identity{min-width:0}.pdf9-brand{font:700 11pt/1.35 "Times New Roman",Times,serif;letter-spacing:0;color:#111}
.pdf9-sheet-head h2,.pdf9-a4-sheet .pdf9-sheet-head h2{margin:2mm 0;font-size:14pt;line-height:1.3}
.pdf9-sheet-meta{margin:1mm 0;font-size:10pt}.pdf9-name{margin:3mm 0 0;padding:0;font-size:10pt}
.pdf9-logo{display:block;width:24mm;height:24mm;object-fit:contain;margin:0 auto}
.pdf9-qr{text-align:center;font:7pt/1.2 "Times New Roman",Times,serif;color:#111;white-space:nowrap}
.pdf9-qr svg{display:block;width:23mm;height:23mm;margin:0 auto}.pdf9-qr span{display:block;margin-top:.5mm}
.pdf9-a4-sheet .pdf9-sheet-head{padding-bottom:3mm}
.pdf9-a4-sheet .pdf9-sheet-question{margin-bottom:4mm}
.pdf9-a4-sheet .pdf9-sheet-part:last-child{margin-bottom:0}
.pdf9-rich .pdf9-tf-table{font-size:1em;line-height:1.35;table-layout:fixed}
.pdf9-rich .pdf9-tf-table th{font-weight:700;text-align:center;padding:1.5mm 1mm}
.pdf9-rich .pdf9-tf-table td{padding:1.5mm 1.3mm;vertical-align:middle}
.pdf9-tf-table th:not(:first-child),.pdf9-tf-table td:not(:first-child){width:10mm;text-align:center}
.pdf9-tf-letter{font-weight:700}.pdf9-tick-box{display:inline-block;width:2.2mm;height:2.2mm;border:.6pt solid #444;vertical-align:middle}
.pdf9-tf-group .pdf9-answer-space{margin-top:2mm}
.pdf9-page-number{font-family:"Times New Roman",Times,serif;letter-spacing:0}
.pdf9-rich math{font-family:"Cambria Math","STIX Two Math",serif}

/* Keep labels inline and check columns readable at two-column print width. */
.pdf9-tf-table th:not(:first-child),.pdf9-tf-table td:not(:first-child){width:12mm;white-space:nowrap}
.pdf9-tf-table td:first-child>p:first-of-type{display:inline;margin:0}
.pdf9-tf-table td:first-child>p:first-of-type+*{margin-top:1mm}

/* 41.27: a clear centre name above a full-width, centred document title. */
.pdf9-masthead{display:block}
.pdf9-brand-block{width:100%;display:grid;grid-template-columns:minmax(0,1fr) 21mm;gap:6mm;align-items:center;text-align:left;color:#111}
.pdf9-brand-contact{min-width:0}
.pdf9-brand-block .pdf9-brand{font:700 17pt/1.25 "Times New Roman",Times,serif;letter-spacing:.025em;margin:0 0 2mm}
.pdf9-brand-details{display:flex;align-items:center;column-gap:5mm;row-gap:1mm;flex-wrap:wrap;font:10pt/1.3 "Times New Roman",Times,serif}
.pdf9-brand-phone,.pdf9-brand-site{white-space:nowrap;margin:0}
.pdf9-brand-block .pdf9-qr,.pdf9-brand-block .pdf9-qr svg{display:block;width:21mm;height:21mm;margin:0;background:#fff}
.pdf9-identity{text-align:center;width:100%;padding:3mm 0 0;margin-top:2mm;border-top:.6pt solid #999}
.pdf9-sheet-head h2,.pdf9-a4-sheet .pdf9-sheet-head h2{font-size:18pt;line-height:1.25;margin:0 0 1.5mm;text-align:center;text-wrap:balance}
.pdf9-sheet-meta{font-size:10.5pt;margin:0;text-align:center}
.pdf9-name{display:grid;grid-template-columns:minmax(0,1fr) 28mm 44mm;gap:7mm;margin:4mm 0 0;padding:0;font-size:10.5pt;text-align:left}
.pdf9-student-field{display:flex;align-items:baseline;gap:1.5mm;min-width:0;white-space:nowrap}
.pdf9-student-blank{flex:1;min-width:4mm;height:3mm;border-bottom:.5pt dotted #666}
.pdf9-sheet-head,.pdf9-a4-sheet .pdf9-sheet-head{border-bottom:0;padding-bottom:1mm}
.pdf9-rich .pdf9-options{display:grid;grid-template-columns:minmax(0,1fr);column-gap:4mm;row-gap:1.5mm;margin-top:2mm}
.pdf9-options .pdf9-option{display:flex;align-items:baseline;gap:1mm;min-width:0;margin:0;padding:0}
.pdf9-option>strong{flex:none}.pdf9-option-content{min-width:0}
.pdf9-rich .pdf9-option-content>p{margin:0}
.pdf9-rich .pdf9-option-content>p:empty{display:none}
.pdf9-rich .pdf9-option-content>p:first-child{display:inline}
.pdf9-rich .pdf9-option-content math{white-space:nowrap}

/* Print-sized data table padding; retain source text size and all rows. */
.pdf9-rich .gssv-stat-table :is(th,td){padding:1.4mm 1.3mm!important}

/* Per-question/per-part writing-room controls. */
.pdf9-work-defaults{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.pdf9-work-defaults label{min-width:0}
.pdf9-work-options #pdf9-edit-work{margin-top:10px;font-size:13px}
.pdf9-work-editor{margin:8px 0 10px 32px;padding:10px 12px;background:#edf6fb;border:1px solid #d4e5ef;border-radius:9px}
.pdf9-work-editor[hidden]{display:none}
.pdf9-work-editor .pdf9-work-edit,.pdf9-work-placement{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:0;padding:6px 0;background:transparent}
.pdf9-work-placement>span,.pdf9-work-editor .pdf9-work-edit>span{flex:1;min-width:120px;margin:0!important;font-size:12px!important}
.pdf9-work-placement select{flex:1.25;min-width:160px!important;min-height:38px!important;font-size:12px!important}
.pdf9-work-editor .pdf9-line-control{display:flex!important;align-items:center;gap:6px;flex:1.25!important;min-width:160px!important}
.pdf9-work-editor input.pdf9-work-count{width:100%;min-height:38px;font-size:13px}
.pdf9-line-unit{font-size:12px;font-weight:400;flex-shrink:0}
.pdf9-work-hint{margin:5px 0 0;color:#526d7e;font-size:11px;line-height:1.5}
@media(max-width:520px){.pdf9-work-defaults{grid-template-columns:1fr}.pdf9-work-editor{margin-left:0}.pdf9-work-placement select,.pdf9-work-editor .pdf9-line-control{flex-basis:100%!important}}


/* Single first-page masthead; later pages retain the full writing area. */
.pdf9-a4-sheet{padding:11mm 12mm 8mm;gap:3mm}
.pdf9-sheet-head .pdf9-identity{border:0;margin:0;padding:0}
.pdf9-sheet-head h2,.pdf9-a4-sheet .pdf9-sheet-head h2{font-size:16pt;line-height:1.25;margin:0 0 1.5mm}
.pdf9-name{margin-top:3mm}
.pdf9-a4-sheet .pdf9-sheet-question{margin-bottom:3mm}
.pdf9-a4-sheet .pdf9-sheet-part{margin-bottom:2.5mm}
.pdf9-a4-sheet .pdf9-sheet-part h4{margin-bottom:1mm}
.pdf9-answer-space{margin-top:2mm}
.pdf9-answer-line{height:7mm;min-height:7mm}
.pdf9-question-continuation>.pdf9-sheet-parts>.pdf9-sheet-part:first-child>.pdf9-answer-space:first-child{margin-top:0}
/* Compact branding and total page count appear only above the first-page title. */
.pdf9-first-masthead{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));align-items:center;gap:0;height:20.5mm;margin:0 0 1.5mm;padding:0 0 1mm;border-bottom:.4pt solid #b8c1c7;color:#111;font:8pt/1.25 "Times New Roman",Times,serif;break-inside:avoid;page-break-inside:avoid}
.pdf9-header-brand{display:flex;align-items:center;gap:2mm;min-width:0;justify-self:start;text-align:left}
.pdf9-header-logo{display:block;flex:none;width:12mm;height:12mm;object-fit:contain}
.pdf9-header-name{display:flex;flex-direction:column;gap:.7mm;min-width:0}
.pdf9-header-name strong{font-size:9.5pt;line-height:1.2;white-space:nowrap}
.pdf9-header-name .pdf9-header-slogan{display:block;max-width:44mm;font-size:7.5pt;line-height:1.25;white-space:normal}
.pdf9-total-pages{margin:0;padding:0;border:0;min-height:3.5mm;text-align:center;align-self:center;white-space:nowrap;font:8pt/1.25 "Times New Roman",Times,serif}
.pdf9-header-qr{width:36mm;justify-self:end;display:flex;flex-direction:column;align-items:center;gap:.35mm}
.pdf9-header-qr .pdf9-qr,.pdf9-header-qr .pdf9-qr svg{display:block;width:16mm;height:16mm;margin:0;background:#fff}
.pdf9-header-site{display:block;font:6.5pt/1.1 Arial,sans-serif;white-space:nowrap;text-decoration:none;color:#111;text-align:center}
@media print{.pdf9-a4-sheet{padding:11mm 12mm 8mm!important;gap:3mm!important}}
