@font-face {
  font-family: "Noto Serif";
  src: url("node_modules/@fontsource/noto-serif/files/noto-serif-latin-400-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Noto Serif";
  src: url("node_modules/@fontsource/noto-serif/files/noto-serif-latin-700-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Noto Serif";
  src: url("node_modules/@fontsource/noto-serif/files/noto-serif-latin-900-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 900;
  font-display: swap;
}
@font-face {
  font-family: "Inconsolata";
  src: url("node_modules/@fontsource/inconsolata/files/inconsolata-latin-400-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Inconsolata";
  src: url("node_modules/@fontsource/inconsolata/files/inconsolata-latin-700-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root {
  color: #171717;
  background: #e9e5dc;
  font-family: "Inconsolata", ui-monospace, monospace;
}

* { box-sizing: border-box; }

body { margin: 0; min-height: 100vh; display: grid; grid-template-columns: 340px minmax(0, 1fr); }

.generator-panel {
  position: sticky; top: 0; height: 100vh; overflow: auto; padding: 28px 24px;
  background: #171817; color: #f7f3ea; border-right: 1px solid #000;
}
.back-link { display: inline-block; margin-bottom: 22px; color: #d3ad5c; font-size: 12px; font-weight: 800; text-decoration: none; }
.back-link:hover { color: #f0d79f; }
.eyebrow { margin: 0 0 8px; color: #c8aa69; font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.generator-heading h1 { margin: 0; font: 700 30px/1.05 "Noto Serif", serif; }
.generator-heading p:last-child { color: #b9bbb7; font-size: 14px; line-height: 1.5; }
.generator-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 22px 0; }
.mode-toggle { display: flex !important; align-items: center; gap: 8px; width: max-content; margin: -8px 0 18px; cursor: pointer; }
.mode-toggle input { width: 16px; height: 16px; margin: 0; accent-color: #d3ad5c; }
.generator-actions .primary { grid-column: 1 / -1; background: #d3ad5c; color: #181713; border-color: #e8ca88; }
button { appearance: none; border: 1px solid #5b5e59; border-radius: 7px; background: #30322f; color: white; padding: 10px 12px; font-weight: 750; cursor: pointer; }
button:hover { filter: brightness(1.12); }
button.quiet { color: #c8cbc5; }
.tool-link { grid-column: 1 / -1; display: block; border: 1px solid #5b5e59; border-radius: 7px; padding: 10px 12px; color: #f7f3ea; font-weight: 750; text-align: center; text-decoration: none; }
.tool-link:hover { background: #30322f; }
.generator-panel label { display: block; margin-bottom: 8px; font-size: 13px; font-weight: 800; }
#level-data, #map-data { width: 100%; height: 28vh; resize: vertical; border: 1px solid #575a55; border-radius: 8px; padding: 13px; background: #0f100f; color: #e9e6df; font: 11px/1.5 "Inconsolata", ui-monospace, monospace; tab-size: 2; }
.status { min-height: 20px; margin: 8px 0; color: #aeb2aa; font-size: 12px; }
.status.success { color: #a9d59d; }.status.error { color: #ff9d95; }
details { margin-top: 20px; border-top: 1px solid #3f413e; padding-top: 16px; color: #c8cbc5; font-size: 13px; line-height: 1.5; }
summary { cursor: pointer; font-weight: 800; }

.preview-area { min-width: 0; overflow: auto; }
.preview-toolbar { height: 48px; padding: 0 20px; display: flex; align-items: center; justify-content: space-between; color: #5f5b52; font-size: 12px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.sheet-stage { padding: 0 22px 40px; min-width: 980px; }
.tracker-sheet {
  width: 11in; height: 8.5in; margin: 0 auto; padding: .08in; overflow: hidden;
  background: #fff; color: #090909; box-shadow: 0 8px 35px rgba(41, 35, 24, .23);
  font-family: "Inconsolata", ui-monospace, monospace;
}

.sheet-header { height: .64in; display: grid; grid-template-columns: .7in 3.1in 5.35in 1.3in; gap: .1in; align-items: center; }
.game-logo { display: block; width: .62in; height: .62in; object-fit: contain; }
.game-title { background: #111; color: white; padding: .08in .15in; font-size: 21px; line-height: 1; font-weight: 900; text-align: center; white-space: nowrap; clip-path: polygon(3% 0, 97% 0, 100% 20%, 98% 50%, 100% 80%, 97% 100%, 3% 100%, 0 80%, 2% 50%, 0 20%); }
.level-title { position: relative; border: 2px solid #111; padding: .08in .14in; text-align: center; font-size: 20px; font-weight: 900; line-height: 1.1; clip-path: polygon(3% 0, 97% 0, 100% 50%, 97% 100%, 3% 100%, 0 50%); }
.level-title span { font-size: 18px; }
.difficulty-badge { height: .5in; display: grid; align-content: center; justify-items: center; gap: .025in; border: 1.5px solid #111; border-radius: 7px; text-transform: uppercase; }
.difficulty-badge strong { font-size: 11px; line-height: 1; letter-spacing: .08em; }
.difficulty-dots { display: flex; gap: .055in; }
.difficulty-dots i { width: .09in; height: .09in; border: 1.3px solid #111; border-radius: 50%; }
.difficulty-dots i.filled { background: #111; }
.check-box { width: .15in; height: .13in; border: 1.3px solid #111; display: inline-block; }

.main-grid { height: 5.1in; display: grid; grid-template-columns: 3.05in 3.02in 4.48in; gap: .1in; }
.sheet-panel { border: 1.3px solid #111; border-radius: 8px; overflow: hidden; min-width: 0; }
.game-title, .level-title, .panel-title, .encounter-card h3, .difficulty-badge strong { font-family: "Noto Serif", serif; }
.panel-title { height: .28in; margin: 0; padding: 0 .055in; display: flex; align-items: center; gap: .045in; background: #111; color: white; font-size: 16px; line-height: 1; }
.sheet-icon { flex: 0 0 .27in; width: .27in; height: .27in; background-image: url("deck-n-dice-dungeons-icons.png"); background-repeat: no-repeat; background-size: 900% 100%; }
.icon-party { background-position: 0% 50%; }
.icon-objectives { background-position: 12.5% 50%; }
.icon-enemies { background-position: 25% 50%; }
.icon-loot { background-position: 37.5% 50%; }
.icon-star { background-position: 50% 50%; }
.icon-notes { background-position: 62.5% 50%; }
.icon-dice { background-position: 75% 50%; }
.icon-people { background-position: 87.5% 50%; }
.icon-rewards { background-position: 100% 50%; }
.panel-body { height: calc(100% - .28in); padding: .07in; }

.party-panel .panel-body { display: grid; grid-template-rows: repeat(3, 1fr); gap: .06in; }
.hero-card { position: relative; min-height: 0; display: grid; grid-template-columns: .9in 1fr; gap: .09in; padding: .055in .05in .035in .065in; border: 1px solid #111; border-radius: 7px; }
.hero-number { position: absolute; top: 0; left: .055in; width: .29in; height: .4in; padding-top: .02in; background: #111; color: white; font: 900 18px/1 "Noto Serif", serif; text-align: center; clip-path: polygon(0 0,100% 0,100% 100%,50% 82%,0 100%); }
.card-write-field { display: grid; grid-template-rows: auto .19in auto auto auto auto; align-content: center; justify-items: stretch; padding-top: .11in; text-align: center; font-size: 10px; }
.card-write-field span { display: block; width: calc(100% - .06in); justify-self: start; border-bottom: 1.5px solid #111; }
.card-write-field small { margin-top: 2px; color: #333; font-size: 8px; }
.card-write-field .pool-instruction { margin-top: .04in; font-size: 8px; font-weight: 700; line-height: 1.05; white-space: nowrap; }
.card-write-field .pool-options { margin-top: 1px; font-size: 9px; font-weight: 700; line-height: 1.05; }
.card-write-field .minimum-hp { margin-top: 2px; font-size: 7.5px; font-weight: 700; line-height: 1; }
.hero-fields { display: grid; align-content: space-between; font-size: 10px; font-weight: 700; }
.write-line { display: flex; gap: .06in; align-items: end; }.write-line span { flex: 1; height: .12in; border-bottom: 1px solid #111; }
.stat-pair, .stat-trio { display: flex; align-items: center; justify-content: space-between; }
.stat-pair label, .stat-trio label { display: flex; gap: 3px; align-items: center; white-space: nowrap; }
.hero-fields i { display: inline-block; width: .22in; height: .21in; border: 1px solid #111; font-style: normal; }
.hero-fields .stat-wide i { width: .28in; }
.hp-row { display: flex; align-items: center; gap: .025in; }.hp-row strong { margin-right: .04in; }.hp-box { width: .14in; height: .14in; border: 1px solid #111; }

.middle-stack { display: grid; grid-template-rows: 1.02in 1.72in .83in 1.35in; gap: .06in; }
.check-list, .reward-list { list-style: none; margin: 0; padding: 0; }
.check-list li { display: flex; align-items: center; gap: .08in; margin-bottom: .035in; font-size: 12px; font-weight: 700; }
.check-list i, .reward-list i { flex: 0 0 auto; width: .14in; height: .14in; border: 1.2px solid #111; }
.upgrades-panel .panel-body { padding: .045in; }
table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.upgrade-table { height: 100%; font-size: 9px; }.upgrade-table th,.upgrade-table td { border: 1px solid #222; padding: 1px 3px; }.upgrade-table th:nth-child(1){width:17%}.upgrade-table th:nth-child(2){width:41%}.upgrade-table th:nth-child(4){width:8%}.tiny-check{display:block;width:.11in;height:.11in;border:1px solid #111}
.carryover-panel .panel-title { font-size: 14px; }.carryover-list { padding-left: .12in; }
.note-lines { display: grid; gap: .09in; }.note-lines i { height: .11in; border-bottom: 1px solid #111; }

.encounters-panel .panel-body { display: grid; grid-template-rows: repeat(4, 1fr); gap: .1in; }
.encounter-card { min-height: 0; border: 1px solid #111; border-radius: 7px; overflow: hidden; }
.encounter-card header { height: .38in; display: grid; grid-template-columns: .4in 1fr; align-items: stretch; background: #eee; }
.encounter-card header b { align-self: stretch; display: grid; place-items: center; background: #111; color: white; font-size: 17px; clip-path: polygon(0 0, 85% 0, 100% 50%, 85% 100%, 0 100%); }
.encounter-heading { min-width: 0; display: grid; align-content: center; gap: 1px; padding: 1px .08in; }
.encounter-card h3 { margin: 0; font-size: 12px; line-height: 1; }
.encounter-heading span { min-width: 0; overflow: hidden; text-overflow: clip; white-space: nowrap; font-size: 9px; line-height: 1; }
.encounter-card table { height: calc(100% - .38in); font-size: 8px; }.encounter-card th,.encounter-card td { border: 1px solid #333; height: .17in; padding: 0 1px; text-align:center; }.encounter-card th:nth-child(1){width:10%}.encounter-card th:nth-child(2){width:18%}.encounter-card th:nth-child(3){width:7%}.encounter-card th:nth-child(4){width:8%}.encounter-card th:nth-child(5){width:6%}.encounter-card th:nth-child(6){width:6%}.encounter-card th:nth-child(7){width:7%}.encounter-card th:nth-child(8){width:7%}

.footer-grid { height: 2.52in; margin-top: .08in; display: grid; grid-template-columns: 2.3in 3.1in 2.4in 2.65in; gap: .1in; }
.footer-grid .panel-title { font-size: 14px; }
.footer-grid .panel-body { padding: .03in .06in; }
.quick-list { list-style: none; margin: 0; padding: 0; font-size: 9px; line-height: 1.15; }
.quick-list li { position: relative; padding-left: .1in; margin: .035in 0; }
.quick-list li::before { content: "•"; position: absolute; left: 0; }
.reference-table { height: 100%; font-size: 8px; }.reference-table th,.reference-table td { border: 1px solid #333; padding: 1px 2px; text-align:center; line-height: 1.05; }.reference-table td:last-child { text-align:left; }.reference-table .suit { font-size: 13px; }.hero-table th:last-child { width: 39%; }.hero-table th:nth-child(1) { width: 8%; }.hero-table th:nth-child(2) { width: 17%; }
.reward-list { display: grid; gap: .04in; font-size: 9px; line-height: 1.1; }.reward-list li { display: flex; gap: .06in; align-items: start; }.reward-list i { width: .13in; height: .13in; }

/* Ink-saving tracker palette. */
.tracker-sheet.light-mode .game-title,
.tracker-sheet.light-mode .panel-title,
.tracker-sheet.light-mode .hero-number,
.tracker-sheet.light-mode .encounter-card header b {
  background: #fff;
  color: #111;
  border: 1.5px solid #111;
}
.tracker-sheet.light-mode .game-title { border-width: 2px; }
.tracker-sheet.light-mode .panel-title { border-width: 0 0 1.3px; }
.tracker-sheet.light-mode .hero-number { border-width: 0 1.3px 1.3px 0; }
.tracker-sheet.light-mode .encounter-card header b { border-width: 0 1.3px 1.3px 0; }
.tracker-sheet.light-mode .sheet-icon { filter: invert(1); opacity: .58; }

@page { size: letter landscape; margin: 0; }
@media print {
  body { display: block; background: white; }
  .generator-panel, .preview-toolbar { display: none !important; }
  .preview-area, .sheet-stage { margin: 0; padding: 0; min-width: 0; overflow: visible; }
  .tracker-sheet { margin: 0; box-shadow: none; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .tracker-sheet, .map-sheet { break-after: page; page-break-after: always; }
  .map-sheet { break-after: auto; page-break-after: auto; }
}

@media (max-width: 900px) {
  body { display: block; }
  .generator-panel { position: static; width: 100%; height: auto; }
  #level-data, #map-data { height: 320px; }
}

:root{--ink:#171914;--green:#283b2c;--paper:#fff;--pit:#29272e;--accent:#b4236d}.maze-app{display:grid;grid-template-columns:340px minmax(0,1fr);min-height:100vh;background:#e7e4dc}.maze-controls{padding-bottom:40px}.maze-controls .control-section{display:grid;gap:14px;padding-top:18px;border-top:1px solid #444}.maze-controls label{display:grid;gap:6px;color:#c8cbc5;font-size:12px}.maze-controls input,.maze-controls select{box-sizing:border-box;width:100%;padding:9px;border:1px solid #575a55;border-radius:7px;background:#0f100f;color:#fff}.pack-pages{min-width:860px;padding:26px 34px 50px;display:grid;gap:28px}.paper{width:8.5in;height:11in;box-sizing:border-box;margin:auto;padding:.35in;background:#fff;color:var(--ink);box-shadow:0 8px 35px #291f1829;display:flex;flex-direction:column;font:11px/1.25 ui-monospace,monospace}.sheet-head{display:flex;justify-content:space-between;align-items:end;border-bottom:4px solid var(--green);padding-bottom:8px}.sheet-head p{margin:0;font-weight:900;letter-spacing:.16em}.sheet-head h2{margin:2px 0 0;font:900 25px/1 Arial,sans-serif}.sheet-head>span{font-weight:900}.two-levels{display:grid;grid-template-rows:1fr 1fr;gap:12px;flex:1;min-height:0;padding:12px 0}.level-card{display:grid;grid-template-columns:1fr 3.75in;grid-template-rows:auto 1fr auto;gap:5px 14px;border:2px solid var(--green);border-radius:12px;padding:10px;min-height:0}.level-card header{grid-column:1;align-self:start;display:grid;gap:5px}.level-card header div{display:grid}.level-card header span{font:900 16px/1 Arial,sans-serif}.level-card header b{font-size:8px}.difficulty{justify-self:start;padding:5px 10px;background:var(--green);color:#fff;border-radius:99px;text-transform:uppercase;font:900 10px/1 Arial,sans-serif}.difficulty.medium{background:#6a5626}.difficulty.hard{background:#711f28}.level-card .maze-svg{grid-column:2;grid-row:1/4;width:100%;height:100%;max-height:3.8in}.level-card footer{grid-column:1;align-self:end;display:grid;gap:6px;font-size:9px}.maze-svg{background:#fff;border:2px solid #111}.grid path{stroke:#bbb;stroke-width:.55}.wall{fill:#91aa9a}.pit{fill:var(--pit)}.pit+.grid{}.jump-token circle,.marker circle{fill:#111;stroke:#fff;stroke-width:2}.jump-token text,.marker text{fill:#fff;text-anchor:middle;font:900 22px Arial,sans-serif}.finish circle{fill:var(--accent)}.solution-route{fill:none;stroke:var(--accent);stroke-width:7;stroke-linecap:round;stroke-linejoin:round;opacity:.82}.sheet-key{border:2px solid var(--green);border-radius:8px;padding:8px;text-align:center;font-size:9px}.solutions{display:grid;grid-template-columns:1fr 1fr;gap:22px;padding:28px 0;flex:1;align-items:center}.solution-card{border:2px solid var(--green);border-radius:12px;padding:12px}.solution-card header{display:flex;justify-content:space-between;font-weight:900;margin-bottom:8px}.solution-card .maze-svg{width:100%;height:auto}.solution-card p{text-align:center;margin:8px 0 0}.solution-note{text-align:center;border-top:2px solid var(--green);padding-top:10px}@page{size:letter portrait;margin:.2in}@media print{html,body{margin:0!important;background:#fff}.generator-panel,.preview-toolbar{display:none!important}.maze-app{display:block}.pack-pages{display:block;min-width:0;padding:0}.paper{width:8.1in;height:10.6in;margin:0;box-shadow:none;break-after:page}.paper:last-child{break-after:auto}}@media screen and (max-width:900px){.maze-app{display:block}.pack-pages{transform:scale(.58);transform-origin:top left}}

/* Legacy authored-map rendering: match the original printed puzzle language. */
.maze-svg{background:#fff;border:0}.pit{fill:inherit;stroke:none}.wall{fill:#999;stroke:none}.wall-edge{fill:none;stroke:#222;stroke-width:2.2;stroke-linecap:square}.jump-token circle{fill:#fff;stroke:#444;stroke-width:4}.jump-token text{fill:#333;text-anchor:middle;font:700 44px Arial,sans-serif}.word-marker{fill:#111;text-anchor:middle;font:700 20px/1 ui-monospace,monospace;paint-order:stroke;stroke:#fff;stroke-width:4px;stroke-linejoin:round}.outer-border{fill:none;stroke:#27242a;stroke-width:5}

/* Minimal two-up print layout: labels and mazes only. */
.puzzle-sheet,.solution-sheet{padding:.14in}
.puzzle-sheet .two-levels{padding:0;gap:.02in}
.level-card{display:grid;grid-template-columns:1fr;grid-template-rows:1fr auto;gap:0;border:0;border-radius:0;padding:0}
.level-card .maze-svg{grid-column:1;grid-row:1;width:100%;height:4.95in;max-height:none}
.level-label{display:flex;justify-content:flex-end;align-items:center;gap:7px;height:.18in;font:800 11px/1 Arial,sans-serif;text-transform:uppercase}
.level-card .level-label{width:4.95in;justify-self:center}
.level-label strong{font-size:9px;letter-spacing:.08em}
.difficulty-dots{font:900 18px/.8 Arial,sans-serif;letter-spacing:-2px}
.solutions{grid-template-columns:1fr 1fr;gap:.2in;padding:0;align-items:start}
.solution-card{border:0;border-radius:0;padding:0}
.solution-card{display:flex;flex-direction:column}
.solution-card .level-label{order:2;margin-top:2px}
.solution-card p,.solution-note,.sheet-key{display:none}
.outer-border{display:block}

/* Markers are drawn to fill their 2x2 cell block; sizes come from the grid. */
.jump-token circle{fill:#fff;stroke:#444}
.jump-token text{fill:#444;text-anchor:middle;font-family:Arial,sans-serif;font-weight:700}
.word-marker rect{fill:#fff;stroke:#111;stroke-width:3}
.word-marker text{fill:#111;stroke:none;text-anchor:middle;font-family:"Arial Narrow",Arial,sans-serif;font-weight:700}
.word-marker.finish rect{stroke-width:5;stroke-dasharray:7 4}
#details{display:block;margin-top:4px}

/* Three-up: easy and medium side by side, hard featured below. */
.three-levels{display:grid;grid-template-columns:3.8in 3.8in;grid-template-rows:auto auto;justify-content:center;align-content:space-evenly;column-gap:.18in;flex:1;min-height:0;padding:0}
.three-levels>.hard{grid-column:1/-1;justify-self:center;width:5.9in}
.three-levels.with-side{grid-template-columns:repeat(2,3.8in)}
.three-levels.with-side>.hard{grid-column:1/-1;grid-row:2;justify-self:start;width:5.75in}
.sheet-side{grid-row:2;grid-column:2;justify-self:end;width:1.85in;display:flex;flex-direction:column;align-items:center;justify-content:space-between;padding-bottom:.18in}
.title-block{width:100%;height:auto}
.sheet-side figure{margin:0;display:grid;justify-items:center;gap:2px}
.sheet-side .qr{width:1.5in;height:1.5in}
.sheet-side figcaption{font:900 13px/1 Arial,sans-serif;letter-spacing:.1em;text-transform:uppercase}
.three-levels .maze-svg{width:100%;height:auto;aspect-ratio:1;max-height:none}
.three-levels .level-card .level-label,.three-levels .solution-card .level-label{width:100%}

/* Saved levels, the month stamp, and printing one sheet at a time. */
.saved{display:grid;gap:8px}.saved-actions{display:grid;grid-template-columns:1fr 1fr;gap:6px}.maze-controls .saved-actions button{padding:8px;border:1px solid #575a55;border-radius:7px;background:#2b2d2a;color:#fff;cursor:pointer}.maze-controls .saved-actions button:disabled{opacity:.4;cursor:default}
.paper{position:relative}.edition-stamp{font:700 9px/1 Arial,sans-serif;letter-spacing:.1em}.paper>.edition-stamp{position:absolute;left:.14in;bottom:.04in}
@media print{body[data-print=levels] .solution-sheet,body[data-print=solutions] .puzzle-sheet{display:none}body[data-print] .paper{break-after:auto}}
/* Keeps ink use low. */
.title-block image{opacity:.55}

.rules-sheet{height:11in}.rules-grid{display:grid;grid-template-columns:1fr 1fr;gap:22px 28px;padding:24px 0}.rules-grid section{border:2px solid #283b2c;border-radius:12px;padding:16px}.rules-grid h3{margin:0 0 8px;background:#283b2c;color:#fff;padding:7px 10px;font:900 14px/1 Arial,sans-serif;text-transform:uppercase}.rules-grid p,.rules-grid li{font-size:12px;line-height:1.45}.legend{display:grid;grid-template-columns:38px 1fr;gap:9px;align-items:center}.legend i{width:30px;height:30px;border:1px solid #777}.legend .wall{background:#999;border-color:#222}.legend .pit{background:repeating-linear-gradient(135deg,#d8d8d8 0 4px,#aaa 4px 5px)}.legend .route{height:5px;background:#b4236d;border:0}.rule-callout{margin-top:16px;padding:12px;background:#edf1ec;border-left:5px solid #283b2c}@media print{.rules-sheet{width:8.1in;height:10.6in}}

.quick-ref ol{list-style:none;margin:0;padding:0;display:grid;gap:12px}.quick-ref li{display:grid;grid-template-columns:40px 14px 1fr;gap:8px;align-items:center}.quick-ref li svg{display:block}.quick-ref li p{margin:3px 0 0;font-weight:700}.qr-find{display:grid;justify-items:center;gap:2px;font:700 11px/1 Arial,sans-serif;text-transform:uppercase}.qr-find b{width:34px;height:34px;display:grid;place-items:center;border-radius:50%;background:#111;color:#fff;font-size:22px}.qr-eq{font:900 22px Arial,sans-serif}.quick-ref .qr-note{text-align:right;font-weight:700}.rules-sheet,.rules-sheet *{-webkit-print-color-adjust:exact;print-color-adjust:exact}
.quick-ref>svg{position:absolute}.legend+h3{margin-top:14px}
.legend .pit-swatch{width:32px;height:32px;border:0}

body.rules-app { display: block !important; margin: 0; }
.rules-preview { padding: 24px 0; }
@media screen and (max-width: 860px) { .rules-preview { padding: 0; } .rules-preview .rules-sheet { width: 100%; height: auto; padding: 16px; box-shadow: none; } .rules-grid { grid-template-columns: 1fr; } .rules-grid p, .rules-grid li, .legend span { font-size: 15px; } }
