body[data-view=memo] .layout,body[data-view=memo] #budgetDock{display:none}
#memo[hidden]{display:none}
#memo{max-width:1120px;margin:auto;padding:20px 16px 48px}
.memo-controls{margin-bottom:24px}.memo-controls h2{margin:0 0 8px;font-size:24px}.memo-controls p{font-size:14px;line-height:1.5}.memo-controls fieldset{border:0;padding:0;margin:18px 0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.memo-controls legend{font-size:16px;font-weight:700;margin-bottom:10px}.memo-layout-choice{display:flex;align-items:center;gap:12px;border:1px solid #60717a;padding:16px;border-radius:8px;cursor:pointer;background:#242b30}.memo-layout-choice:has(input:checked){border:2px solid #a5cfdf;padding:15px;background:#34464f}.memo-layout-choice input{accent-color:#a5cfdf}.memo-layout-choice b{display:block;font-size:16px}.memo-layout-choice small{display:block;font-size:14px;line-height:1.45;margin-top:6px;color:#d2dbe0}.memo-actions{display:flex;gap:12px;flex-wrap:wrap}.memo-print-help{color:#c2ccd2}.memo-mini{display:grid;width:42px;height:60px;flex:0 0 42px;background:#f9f6ee;padding:5px;gap:3px;border:1px solid #bec8cc}.memo-mini i{background:#243946;height:8px;grid-column:1/-1}.memo-mini b{background:#b2c2c9;height:6px;grid-column:1/-1}.memo-mini em{background:repeating-linear-gradient(#a9b6bd 0 2px,transparent 2px 5px)}.codex-mini,.compact-mini{grid-template-columns:1fr 1fr}.compact-mini em{border-top:4px solid #243946}.large-mini{grid-template-columns:1fr}
.memo-document{--memo-ink:#1c303d;--memo-accent:#956f24;box-sizing:border-box;background:#fcfaf5;color:#17232b;width:210mm;max-width:100%;margin:auto;padding:12mm;box-shadow:0 3px 18px #0005;font:10pt/1.38 Arial,sans-serif;overflow-wrap:anywhere}
.memo-document *{box-sizing:border-box}.memo-document h1,.memo-document h2,.memo-document h3,.memo-document h4{line-height:1.18}.memo-document h1{font:700 25pt/1.12 Georgia,serif;margin:5mm 0 3mm}.memo-document h2{font:700 19pt/1.18 Georgia,serif;margin:0}.memo-document h3{font-size:11pt;margin:0}.memo-document h4{font-size:10pt;margin:0 0 1.5mm}.memo-document p{margin:0 0 2mm}.memo-document dl{margin:0}.memo-document dt{font-size:8.5pt;font-weight:700;text-transform:uppercase;color:#405867;margin:2mm 0 .8mm}.memo-document dd{margin:0 0 2mm}.memo-document footer{font-size:7.5pt;color:#51616a;margin-top:3mm;border-top:1px solid #bbc5c9;padding-top:2mm;overflow-wrap:anywhere}
.memo-section{margin:0 0 10mm}.memo-section-header,.memo-unit-header{background:var(--memo-ink);border-top:3px solid var(--memo-accent);color:white;padding:5mm;margin-bottom:5mm}.memo-section-header small,.memo-unit-header small{display:block;font-size:8.5pt;text-transform:uppercase;letter-spacing:.6px;margin-bottom:2mm}.memo-section-header p{margin:3mm 0 0}.memo-section-header h2 span{float:right;font:700 13pt Arial,sans-serif}.memo-divider{border-bottom:2px solid var(--memo-accent);padding-bottom:2mm;margin:5mm 0 3mm!important;text-transform:uppercase}.memo-warning{border:1px solid #926b21;padding:3mm;background:#fff1c9;color:#39290b}.memo-roster-det{position:relative;border-bottom:1px solid #b7c2c8;padding:3mm 0}.memo-roster-det strong{float:right}.memo-roster-det p{margin:2mm 0 0;font-size:9pt}.memo-roster,.memo-weapons{width:100%;border-collapse:collapse;table-layout:fixed;font-size:9pt}.memo-roster th,.memo-weapons th{background:#e0e7eb;color:var(--memo-ink);text-align:left;border-bottom:2px solid #6e8794;padding:2mm 1.5mm}.memo-roster td,.memo-weapons td{padding:2mm 1.5mm;border-bottom:1px solid #becbd1;vertical-align:top}.memo-roster th:first-child{width:10%}.memo-roster th:nth-child(2){width:65%}.memo-roster th:nth-child(3){width:12%}.memo-roster th:last-child{width:13%}.memo-roster small,.memo-weapons small{display:block;font-size:8pt;font-weight:400;line-height:1.35;margin-top:1mm}.memo-weapons th:first-child{width:38%}.memo-weapons th:nth-child(2){width:14%}.memo-weapons th:nth-child(n+3){width:9.6%}.memo-weapons td:nth-child(n+2),.memo-weapons th:nth-child(n+2){text-align:center}.memo-weapons{font-size:8pt}.memo-weapons th,.memo-weapons td{padding:1.5mm .9mm}
.memo-unit{margin-bottom:8mm;border-bottom:1px solid #b5c3c9;padding-bottom:3mm}.memo-unit-header{display:flex;justify-content:space-between;gap:5mm;margin-bottom:3mm}.memo-unit-header h2{font-size:19pt}.memo-unit-header p{margin:2mm 0 0}.memo-unit-header>strong{font-size:13pt;white-space:nowrap}.memo-stats{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:1.5mm;margin:0 0 4mm}.memo-stats>div{display:flex;flex-direction:column;align-items:center;border:1px solid #618394;padding:2mm 0;background:white}.memo-stats b{font-size:15pt}.memo-stats span{font-size:8pt;font-weight:700;color:#476879}.memo-unit-body,.memo-two-columns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4mm;align-items:start}.memo-box{margin-bottom:3mm;border:1px solid #b7c5cc;background:white}.memo-box>h3{background:#d9e4ea;color:#223d4b;border-bottom:1px solid #a6beca;padding:2mm 3mm;font:700 10pt/1.2 Arial,sans-serif;text-transform:uppercase}.memo-box>p,.memo-box>.memo-ability,.memo-box>dl,.memo-box>.memo-bonus,.memo-box>h4{margin:3mm}.memo-ability+ .memo-ability{padding-top:2mm;border-top:1px solid #d7dee2}.memo-keywords{font-size:8.5pt;line-height:1.4}.memo-box>.memo-keywords{margin:3mm}.memo-bonus{border-left:3px solid var(--memo-accent);padding-left:2mm;font-size:9pt}.memo-target{font-size:9pt;color:#455e6b}.memo-source-note{font-size:8.5pt;color:#455e6b}.memo-restriction{font-weight:700;color:#5a271f}.memo-stratagem{border:1px solid #8ca5b3;background:white;margin-bottom:4mm}.memo-stratagem>header{display:flex;gap:3mm;justify-content:space-between;align-items:center;background:var(--memo-ink);color:white;padding:3mm}.memo-stratagem header h3{font-size:11pt;text-transform:uppercase}.memo-stratagem header strong{font-size:11pt;white-space:nowrap;padding:1mm 2mm;border:1px solid #ddc28a}.memo-stratagem dl{padding:0 3mm 2mm}.memo-stratagem footer{margin:0 3mm 3mm}.memo-unit-section-title{display:none}
.layout-compact{font-size:9pt}.layout-compact .memo-unit-sheets{column-count:2;column-gap:5mm}.layout-compact .memo-unit{break-inside:avoid;display:block}.layout-compact .memo-unit-body{display:block}.layout-compact .memo-unit-header{padding:3mm;gap:2mm}.layout-compact .memo-unit-header h2{font-size:13pt}.layout-compact .memo-unit-header>strong{font-size:10pt}.layout-compact .memo-stats{gap:.7mm}.layout-compact .memo-stats b{font-size:12pt}.layout-compact .memo-stats span{font-size:7pt}.layout-compact .memo-document footer,.layout-compact footer{font-size:7pt}.layout-compact .memo-unit .memo-box>h3{font-size:9pt}.layout-compact .memo-unit .memo-box>p,.layout-compact .memo-unit .memo-box>.memo-ability{margin:2mm}.layout-compact .memo-unit h4{font-size:9pt}.layout-compact .memo-unit .memo-keywords{font-size:8pt}
.layout-large{font-size:12pt}.layout-large .memo-unit-body,.layout-large .memo-two-columns{grid-template-columns:1fr}.layout-large .memo-weapons,.layout-large .memo-roster{font-size:10pt}.layout-large .memo-keywords,.layout-large .memo-bonus,.layout-large .memo-target{font-size:11pt}.layout-large h4{font-size:12pt}.layout-large .memo-box>h3,.layout-large .memo-stratagem header h3{font-size:12pt}.layout-large dt{font-size:10pt}.layout-large .memo-stats b{font-size:18pt}
@media(max-width:850px){.memo-controls fieldset{grid-template-columns:1fr}.memo-mini{width:42px}.memo-document{padding:6mm}.memo-unit-body,.memo-two-columns{grid-template-columns:1fr}.layout-compact .memo-unit-sheets{column-count:1}}
@page{size:A4 portrait;margin:12mm}
@media print{
 html,body{background:white!important;margin:0!important;padding:0!important;color:#17232b!important}
 body>.app>header,body>.app>.site-tabs,.layout,#armyBuilder,#catalogue,#detachments,#armyRules,#budgetDock,.memo-controls,.footer-note{display:none!important}
 #memo,#memo[hidden]{display:block!important;max-width:none!important;margin:0!important;padding:0!important}
 .memo-document{display:block!important;width:auto!important;max-width:none!important;margin:0!important;padding:0!important;box-shadow:none!important;background:white!important;-webkit-print-color-adjust:exact;print-color-adjust:exact}
 .memo-section{break-before:page;margin:0}.memo-cover{break-before:auto}
 .memo-unit{break-before:page;margin-bottom:0;border-bottom:0}.memo-unit-section-title{display:none}
 .memo-unit-body,.memo-two-columns{grid-template-columns:repeat(2,minmax(0,1fr))}
 .memo-section-header,.memo-unit-header,.memo-stats{break-inside:avoid;break-after:avoid}
 .memo-box>h3,.memo-divider,.memo-ability>h4{break-after:avoid}
 .memo-katah,.memo-enhancement,.memo-stratagem,.memo-roster-det,.memo-ability{break-inside:avoid}
 .memo-roster tr,.memo-weapons tr{break-inside:avoid}thead{display:table-header-group}
 .memo-unit-body>div{min-width:0}.memo-unit-body .memo-box{break-inside:auto}
 .layout-compact .memo-unit-sheets{column-count:2;column-gap:5mm}.layout-compact .memo-unit{break-before:auto;margin-bottom:5mm;border-bottom:1px solid #b5c3c9}.layout-compact .memo-unit-body{display:block}
 .layout-large .memo-unit-body,.layout-large .memo-two-columns{grid-template-columns:1fr}
}

.memo-weapons th{font-size:7.5pt;white-space:nowrap}.memo-army-rules .memo-box>p,.memo-army-rules .memo-box>dl,.memo-army-rules .memo-box>.memo-bonus{margin:2mm}.memo-army-rules .memo-box>h3{padding:1.5mm 2mm}.memo-army-rules .memo-box{margin-bottom:2mm}
.memo-document table{min-width:0;max-width:100%}
.memo-document th{position:static;letter-spacing:0}
.memo-roster th,.memo-roster td{font-size:9pt}
.memo-weapons td{font-size:8pt}
.memo-strata-grid{display:grid;grid-template-columns:repeat(var(--strata-columns),minmax(0,1fr));gap:3mm;align-items:start}
.memo-army-rules,.memo-detachment-single{font:9.5pt/1.25 Arial,sans-serif}
.memo-army-rules .memo-section-header,.memo-detachment-single .memo-section-header{padding:3mm;margin-bottom:3mm}
.memo-army-rules .memo-section-header h2,.memo-detachment-single .memo-section-header h2{font-size:18pt}
.memo-army-rules .memo-two-columns:not(.memo-katah-grid){grid-template-columns:repeat(3,minmax(0,1fr));gap:3mm}
.memo-army-rules .memo-katah-grid{gap:2mm 3mm}
.memo-army-rules dt,.memo-detachment-single dt{display:inline;margin:0 1mm 0 0;font-size:8pt;line-height:1.25}
.memo-army-rules dt:after,.memo-detachment-single dt:after{content:" :"}
.memo-army-rules dd,.memo-detachment-single dd{display:inline;margin:0;line-height:1.25}
.memo-army-rules .memo-field,.memo-detachment-single .memo-field{margin-bottom:1.5mm}
.memo-army-rules .memo-divider,.memo-detachment-single .memo-divider{margin:3mm 0 2mm!important;font-size:10pt}
.memo-army-rules .memo-bonus{font-size:9pt}
.memo-detachment-single .memo-box>p,.memo-detachment-single .memo-box>.memo-ability{margin:2mm}
.memo-detachment-single .memo-box>h3{padding:1.5mm 2mm;font-size:9pt}
.memo-detachment-single .memo-box{margin-bottom:2mm}
.memo-detachment-single .memo-two-columns{gap:3mm}
.memo-detachment-single .memo-stratagem>header{padding:2mm;gap:1mm}
.memo-detachment-single .memo-stratagem header h3{font-size:9pt}
.memo-detachment-single .memo-stratagem header strong{font-size:9pt;padding:.7mm 1mm}
.memo-detachment-single .memo-stratagem dl{padding:2mm}
.memo-detachment-single .memo-stratagem{margin-bottom:0;font-size:9pt}
.memo-detachment-single .memo-stratagem footer{margin:0 2mm 2mm}
.memo-detachment-single .memo-target,.memo-detachment-single .memo-source-note{font-size:8.5pt}
.memo-detachment-single h4{font-size:9.5pt}
@media(max-width:850px){.memo-strata-grid,.memo-army-rules .memo-two-columns:not(.memo-katah-grid){grid-template-columns:1fr}}
@page{@bottom-left{content:"ADEPTUS CUSTODES · MÉMO DE PARTIE";font:7pt Arial,sans-serif;color:#51616a}@bottom-right{content:counter(page);font:8pt Arial,sans-serif;color:#51616a}}
@media print{
 .app{display:block;min-height:0}
 .layout-compact .memo-unit{break-inside:auto}.memo-document footer{break-inside:avoid}
 .memo-army-rules,.memo-detachment-single{break-inside:avoid}
 .memo-army-rules .memo-two-columns:not(.memo-katah-grid){grid-template-columns:repeat(3,minmax(0,1fr))}
 .memo-strata-grid{grid-template-columns:repeat(var(--strata-columns),minmax(0,1fr))}
 .layout-large .memo-army-rules,.layout-large .memo-detachment-single{font-size:9.5pt}
 .layout-large .memo-army-rules .memo-katah-grid,.layout-large .memo-detachment-single .memo-two-columns{grid-template-columns:repeat(2,minmax(0,1fr))}
 .layout-large .memo-army-rules .memo-bonus,.layout-large .memo-army-rules h4{font-size:9pt}
}

.memo-army-rules .memo-katah-grid{display:block;column-count:2;column-gap:3mm}
.memo-army-rules .memo-katah{display:block;break-inside:avoid;margin-bottom:2mm}
@media(max-width:850px){.memo-army-rules .memo-katah-grid{column-count:1}}
@media print{.memo-army-rules .memo-katah-grid{column-count:2}}
