
body:not([data-site="1818"]) .module[style] h2{min-height:var(--paper-h);font-size:var(--paper-heading);line-height:1.12}
body:not([data-site="1818"]) .module[style] h2 .column-title{font-size:inherit;line-height:inherit}
body:not([data-site="1818"]) .sage-row{--sage-font-family:Arial,"Microsoft YaHei",sans-serif;--sage-fs:var(--paper-text,16px);--sage-rh:var(--paper-row,28px);font-family:var(--sage-font-family);color:var(--body-fg,#151515);overflow-wrap:anywhere;max-width:100%}
body:not([data-site="1818"]) .sage-row.stack,body:not([data-site="1818"]) .sage-row.levels,body:not([data-site="1818"]) .sage-row.part-table{min-height:0}
body:not([data-site="1818"]) .sage-row .sage-result{font-size:.85em}
body:not([data-site="1818"]) .sage-row.kill-four{font-size:min(var(--paper-text),4.2cqw)}
body[data-site="5858"] .star-row{align-content:center;border-bottom:1px dashed #968a82;line-height:1.28}
.star-row em,.paper-open b{color:#b31220;font-weight:700;font-style:normal}
.star-row small{color:#171717;font-size:.9em}.seven-line{flex-basis:100%}
body[data-site="5858"] .star-tiers,body[data-site="5858"] .star-pairs{display:block;padding:0;min-height:0}
.star-pairs header{padding:.2em;background:var(--title-bg,#eee);color:var(--title-fg,#181818)}
.star-pairs div{padding:.3em}.star-tier{display:grid;grid-template-columns:25% minmax(0,1fr) 25%;align-items:stretch;border-bottom:1px solid #b6a996}
.star-tier>*{align-content:center;padding:.22em 1px}.star-tier>*+*{border-left:1px solid #b6a996}.star-tier span{color:#a52035;font-weight:bold}
body .print-strip,body .print-picture{display:block;width:100%;height:auto;min-height:0;margin:0;padding:0;overflow:hidden}
body .print-strip>.inset-strip,body .print-strip .ribbon{height:100%;min-height:0}
body .print-picture{border:0;background:var(--paper-bg,#f7e8c2)}
body .print-picture img{display:block;width:100%;height:100%;object-fit:contain;margin:0}
body[data-site="0149"] .grade-cell{font-size:min(1em,3.7cqw);white-space:normal;line-height:1.2}
.paper-open{display:inline-block;max-width:100%}.paper-open b,.paper-open strong{display:inline}

.print-picture{container-type:inline-size}
.picture-plate{height:100%;width:100%;overflow:hidden;display:flex;flex-direction:column;align-items:stretch;justify-content:space-between;border:.7cqw double var(--plate-ink,#202573);background:linear-gradient(160deg,#fff8dc,#fff 46%,#f8e3ae);color:var(--plate-ink,#202573);padding:2%}
body[data-site="6868"]{--plate-ink:#794011}body[data-site="9898"]{--plate-ink:#962326}body[data-site="5858"]{--plate-ink:#006a91}
.picture-plate header{display:flex;align-items:center;justify-content:space-between;background:var(--plate-ink,#202573);color:#fff1ab;padding:.6% 3%;font:700 clamp(12px,3.7cqw,32px)/1.2 "Microsoft YaHei",sans-serif}
.picture-plate h3{margin:0;padding:2% 0;font:900 clamp(20px,8cqw,72px)/1.15 "Microsoft YaHei",sans-serif;color:var(--plate-ink,#202573)}
.picture-fields{flex:1;min-height:0;display:flex;flex-direction:column;justify-content:space-evenly;gap:1%;padding:0 3%;overflow:auto}
.picture-fields section{display:flex;align-items:center;gap:2%;border-block-end:1px solid #b69966;text-align:left;padding:.5% 0}
.picture-fields section small{width:21%;font-size:clamp(12px,3.5cqw,30px);font-weight:bold}
.picture-fields p{flex:1;margin:0;line-height:1.25}.picture-fields b{display:inline-block;font:800 clamp(16px,5.2cqw,45px)/1.25 "Microsoft YaHei",sans-serif;color:#98231c}
.picture-plate>footer{background:transparent;padding:1%;font-size:clamp(12px,3cqw,25px);color:inherit}
.picture-plate:has(.picture-fields section:nth-child(6)) h3{font-size:5cqw;padding:0}
.picture-plate:has(.picture-fields section:nth-child(6)) :is(.picture-fields b,.picture-fields small){font-size:min(3.1cqw,26px)}
.green-exclusions{display:grid;grid-template-columns:.95fr .8fr .8fr .9fr .8fr 1.25fr;align-items:stretch;text-align:center;background:#fff;font-size:clamp(12px,3.5cqw,19px)}
.green-exclusions>*{border:1px solid #c8d5cb;padding:3px 0;align-content:center}.green-exclusions small{display:block;font-size:.8em}
.column-page .past-balls{padding:2px 8px;color:#456052;font-size:13px;background:#f4faf5}

body[data-site="5858"] .module[style] h2{font-size:var(--title-size)}
body:not([data-site="1818"]) .sage-row .sage-middle,.star-row>span{font-size:var(--pick-fs,var(--paper-text));font-weight:var(--pick-weight,700)}

body[data-site="5858"] .star-tiers{--star-font:14px;--star-issue:110px;--star-result:90px}
.star-tiers header{background:#ec3039;color:#151515;padding:4px;text-align:center;font:700 24px/1.4 Arial,"Microsoft YaHei",sans-serif}
.star-tier{font:400 var(--star-font)/1.3 Arial,"Microsoft YaHei",sans-serif;grid-template-columns:var(--star-issue) minmax(0,1fr) var(--star-result)}
.star-tier>*{padding:3px 0;white-space:nowrap}.star-tier b,.star-tier span{color:#171717;font-weight:400}.star-tier i{font-style:normal;color:#23368c}.star-tier small{font-size:1em;color:#a52220}
body:not([data-site="1818"]) .sage-row.paired{--sage-left:12%;--sage-right:13%}
body:not([data-site="1818"]) .sage-row.paired small .sage-pick{color:#14365e;font-weight:400}
@media(max-width:640px){body[data-site="5858"] .star-tiers{--star-font:12px;--star-issue:72px;--star-result:70px}.star-tiers header{font-size:18px}}

body[data-site="0149"] .module[data-rule="112"] h2{background:linear-gradient(#afdcc0,#f5fff5);color:#11251b;font-size:clamp(18px,4.8cqw,24px);min-height:32px}
.green-exclusions{font-size:clamp(14px,3.9cqw,20px);font-weight:700}
.green-kill-head{background:#efd5b7;color:#21160f}
.green-exclusions span.excluded{color:#ab151b}.green-exclusions span.touched{color:#514c55}.green-exclusions span small{font-size:.65em;display:inline;margin-left:1px}
.green-six{border:1px solid #239852;font-family:Arial,"Microsoft YaHei",sans-serif;line-height:1.3}
.green-six header{text-align:center;padding:4px 2px;background:#cff4cc;color:#174b2d;font-weight:bold}
.green-six-picks{display:grid;grid-template-columns:43% 57%;background:#fff0e8;color:#202b49}.green-six-picks span{padding:6px 2px}.green-six-picks span+span{border-left:1px solid #41a163}.green-six-picks b{color:#9c1723}
.sheet .green-six footer{padding:3px;text-align:center;background:#f7e2f4;color:#2d2642;border-top:1px solid #57a46c;font-size:clamp(14px,3.9cqw,21px)}.green-six footer strong{background:#fff4ad}

body:not([data-site="1818"]) .part-table .sage-subrow{--sage-rh:clamp(25px,7.2cqw,46px);min-height:var(--sage-rh)}
.green-author .directory-record{text-align:center;border-bottom:1px solid #c9dacd;background:#fff;padding:7px 3px 6px;color:#10131a;font:700 clamp(16px,4.1cqw,21px)/1.45 Arial,"Microsoft YaHei",sans-serif}
.green-author .directory-record header{display:block;position:static;background:none;color:inherit;padding:0;box-shadow:none;min-height:0}
.green-author .directory-record header strong{color:#151c90}.directory-record>div>span{color:#b11d20}.directory-record .paper-open b{color:#a61c20}
.green-author .directory-record.annual{text-align:left;font-size:clamp(14px,3.7cqw,17px);font-weight:400;padding:6px}
body[data-site="0149"] .green-author h2{background:#2329ce;color:#fff;min-height:42px;font-size:clamp(17px,4.6cqw,24px)}
body[data-site="0149"] .green-author[data-area="R"] h2{background:#e4f4e9;color:#245939}
.green-author .directory-rule{font-size:13px;background:#e4f3e8;color:#2b5639;padding:2px 8px}
.green-author .past-balls{font-size:11px;text-align:right}.green-author .past-balls:not([open]){line-height:1.2}

/* Use the same tracks for the current issue, settled rows and historical detail views. */
.sage-row.record-columns,.record-heading,.green-author .directory-record .record-heading{
  display:grid;
  grid-template-columns:var(--sage-left,var(--issue-track,18%)) minmax(0,1fr) var(--sage-right,22%);
  align-items:center;
  text-align:center;
  gap:0;
}
.named-issue{--issue-track:32%}
.sage-row.record-columns>*,.record-heading>*,.sage-subrow>*,.sage-row.kill-four>*{
  min-width:0;
  white-space:normal;
  overflow-wrap:anywhere;
}
.record-heading .sage-result{white-space:normal}
.sage-row .sage-result b{white-space:nowrap}
.star-row .seven-line{grid-column:1/-1}
.paired-fields,.three-pick-groups,.record-caption,.directory-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:center;text-align:center}
.three-pick-groups{grid-template-columns:repeat(3,minmax(0,1fr))}
.paired-fields>*,.three-pick-groups>*{min-width:0;overflow-wrap:anywhere}
.sum-exclusion .paired-fields{grid-template-columns:auto 3.5em;justify-content:center;column-gap:.25em}
.sage-row.kill-four,.module .record-row.killmix{
  display:grid;
  grid-template-columns:minmax(0,14fr) minmax(0,17fr) minmax(0,31fr) minmax(0,17fr) minmax(0,21fr);
  align-items:center;
  text-align:center;
  gap:0;
}
.sage-subrow{grid-template-columns:var(--sage-left,26%) minmax(0,1fr) var(--sage-right,22%)}
.sage-subrow>b{white-space:normal}
body:not([data-site="1818"]) .module:has(.size-table) .colheads{grid-template-columns:var(--sage-left,18%) minmax(0,1fr) var(--sage-right,22%)}
.green-exclusions{grid-template-columns:minmax(0,.95fr) repeat(2,minmax(0,.8fr)) minmax(0,.9fr) minmax(0,.8fr) minmax(0,1.25fr)}
.green-exclusions>*,.panel-line>*,.ladder-line>*{min-width:0;overflow-wrap:anywhere}
.pick-line:has(>small){display:grid;grid-template-columns:28% minmax(0,1fr) 12%;align-items:center}
.pick-line:has(>small)>*{min-width:0;text-align:center;margin-inline:0}

.daily-gallery .daily-tile{display:grid;grid-template-rows:1fr auto;min-width:0;align-items:center;background:#fffaf0;border:1px solid #d6cbb6}
.daily-gallery .daily-tile b{display:block;padding:3px;font-size:clamp(13px,2.8cqw,19px)}
button.daily-inset{display:block;width:100%;padding:0;background:#fff;height:auto;margin:4px 0;border:0}
.daily-inset img{display:block;width:100%;height:auto}
@media(max-width:560px){.daily-gallery>div{grid-template-columns:repeat(2,minmax(0,1fr))}}

#back-to-top {
  position: fixed;
  right: calc(12px + env(safe-area-inset-right, 0px));
  bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  z-index: 20;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 2px;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid #fff;
  border-radius: 10px;
  background: #373331;
  color: white;
  box-shadow: 0 2px 7px #0004;
  font: 600 12px/1.2 sans-serif;
  cursor: pointer;
}
#back-to-top[hidden] { display: none; }
.sheet .ribbon {
  display: grid;
  grid-template-columns: max-content minmax(0, 1.3fr) minmax(0, 1fr);
  height: clamp(52px, 15.7vw, 126px);
  gap: 2%;
  margin: 3px 0;
}
.sheet .ribbon i { padding: .18em .35em; }
.ribbon a { min-width: 0; }
.ribbon-main::after { content: ""; position: absolute; inset: 0; }
.ribbon-main:focus-visible::after { outline: 3px solid #167ada; outline-offset: -3px; }
.ribbon-main:last-child { grid-column: 2 / -1; }
.sheet .ribbon .ribbon-main strong { display: block; white-space: normal; font-size: clamp(18px, 5.3cqw, 43px); }
.ribbon-next { position: relative; justify-self: center; align-content: center; min-height: 44px; }
.sheet .ribbon-next span { display: block; padding: .12em .32em; font-size: clamp(13px, 3.3cqw, 26px); }
:is(.module h2, .ribbon, .dhead, .author-links, .pills) .wave-ink {
  background-color: #fff8e4;
  text-shadow: none;
}
#back-to-top:focus-visible { outline: 3px solid #1673ce; outline-offset: 2px; }
body:has(.green-foot) #back-to-top { bottom: calc(47px + env(safe-area-inset-bottom, 0px)); }

.sage-middle .transfer-line{display:block;padding-block:.12em;overflow-wrap:anywhere}

body[data-site="6868"] [data-play-rule="65"] .transfer-line:has(> small) {
  display: grid;
  grid-template-columns: 4em 4em;
  grid-auto-columns: max-content;
  grid-auto-flow: column;
  justify-content: center;
  align-items: baseline;
  column-gap: .25em;
  text-align: center;
  white-space: nowrap;
}
body[data-site="6868"] [data-play-rule="65"] .transfer-line > small {
  text-align: right;
}

.module .brief-history {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  min-height: clamp(32px, 5.8cqw, 44px);
  padding-inline: 4px;
  border-bottom: 1px solid #ccbfaa;
  background: var(--body-bg, #fff7e3);
  color: #27221e;
  font: 700 clamp(14px, 3.8cqw, 21px)/1.25 Arial, "Microsoft YaHei", sans-serif;
  text-align: center;
  white-space: nowrap;
}
.brief-history .paper-open b,.brief-history .hit {color:#a31222}

body[data-site="9898"] .sage-row[data-play-rule="97"] {
  --sage-rh: clamp(42px, 7cqw, 54px);
  --sage-fs: clamp(16px, 2.8cqw, 22px);
  --pick-fs: clamp(18px, 3cqw, 24px);
  --pick-weight: 700;
  --issue-fg: #2c2822;
  --pick-fg: #183f70;
  --grade-fg: #343d51;
  grid-template-columns: 20% minmax(0, 1fr) minmax(max-content, 29%);
}
body[data-site="9898"] .sage-row[data-play-rule="97"] .sage-result {
  font-size: var(--sage-fs);
  white-space: nowrap;
}

/* 天星资料社「六肖十二码」与上一栏共用标题样式，资料行单独排版。 */
body[data-site="5858"] .module[data-rule="45"] .paired {
  --sage-left: 18%;
  --sage-fs: clamp(15px, 2.9cqw, 24px);
  --pick-fs: clamp(16px, 3.3cqw, 26px);
  --sage-rh: clamp(54px, 8.5cqw, 70px);
  grid-template-columns: var(--sage-left) minmax(0, 1fr) minmax(max-content, 22%);
}
body[data-site="5858"] .module[data-rule="45"] .paired .sage-middle {
  padding: 4px 2px;
  line-height: 1.15;
}
body[data-site="5858"] .module[data-rule="45"] .paired small {
  font: 500 clamp(15px, 2.7cqw, 22px)/1.2 Arial, "Microsoft YaHei", sans-serif;
  font-variant-numeric: tabular-nums;
  text-wrap: balance;
}
body[data-site="5858"] .module[data-rule="45"] .paired .sage-result {
  flex-wrap: nowrap;
  white-space: nowrap;
  font-size: clamp(15px, 3cqw, 25px);
  padding-inline: 3px;
}
body[data-site="5858"] .module[data-rule="45"] .paired .sage-result strong {
  width: auto;
}

/* Short recommendations share a single mobile baseline with the issue and result. */
@media (max-width:640px) {
  .module:is([data-rule="10"],[data-rule="19"]) .sage-bracket,
  .module[data-rule="13"] .pick-punctuation,
  .kill-four .sage-bracket,
  .kill-four .pick-punctuation,
  .sage-row:is([data-play-rule="53"],[data-play-rule="109"]) .pick-punctuation,
  .sage-row[data-play-rule="106"] .pick-punctuation,
  .sage-row[data-play-rule="62"] .pick-punctuation,
  .module[data-rule="56"] .star-row .pick-punctuation {display:none}

  .module[data-rule="10"] .paired-fields {grid-template-columns:1.15fr 1fr}
  .module:is([data-rule="10"],[data-rule="19"]) .record-columns {
    --sage-left:16%; --sage-right:22%;
  }
  .module:is([data-rule="10"],[data-rule="19"]) .record-columns .sage-middle {
    font-size:min(var(--pick-fs,var(--sage-fs)),4.55cqw);
  }
  .module:is([data-rule="10"],[data-rule="19"]) .record-columns .sage-result {
    white-space:nowrap;
    font-size:min(var(--sage-fs,var(--paper-text)),4cqw);
    padding-inline:0;
  }
  .module[data-rule="10"] .sage-label {margin-inline-end:.16em}
  .module .kill-four {
    grid-template-columns:13fr 12fr 29fr 25fr 21fr;
  }
  .module[data-rule="56"] .star-row>span,
  .module .sage-row:is([data-play-rule="62"],[data-play-rule="106"]) .sage-middle {
    font-size:min(var(--pick-fs,var(--paper-text)),3.9cqw);
  }
  .module[data-rule="56"] .star-row em {margin-inline-start:.2em}
  .module[data-rule="4"] .pick-line:has(>small):not(:has(>:nth-child(3))) {
    grid-template-columns:max-content minmax(0,1fr);
    column-gap:.2em;
  }
  .module .sage-row[data-play-rule="53"] .sage-middle {
    display:grid; grid-template-columns:repeat(6,minmax(0,1fr));
    font-size:min(3.8cqw,18px);
  }
  .module .sage-row[data-play-rule="53"] .sage-middle>span {white-space:nowrap}
  .module .sage-row[data-play-rule="109"] .sage-middle,
  body[data-site="0149"] .module:is([data-rule="4"],[data-rule="110"]) .pick-line {
    font-size:min(3.8cqw,18px);
  }
  .module .sage-row[data-play-rule="109"] {--sage-left:14%;--sage-right:19%}
  body[data-site="0149"] .module:is([data-rule="4"],[data-rule="110"]) .value {margin-inline:.04em}
  .module .star-row[data-play-rule="62"] {--sage-left:14%;--sage-right:32%}
  .module .star-row[data-play-rule="62"] .sage-result {font-size:min(3.5cqw,17px)}
  .module .star-row:is([data-play-rule="91"],[data-play-rule="101"],[data-play-rule="105"]) {
    --sage-right:26%;
  }
}
@media (max-width:359px) {
  .module .star-row:is([data-play-rule="101"],[data-play-rule="105"]) {--sage-right:30%}
  .module:is([data-rule="7"],[data-rule="16"],[data-rule="34"],[data-rule="41"]) .sage-bracket,
  .module[data-rule="41"] .pick-punctuation,
  .three-pick-groups .pick-punctuation,
  .sage-row[data-play-rule="86"] .pick-punctuation {display:none}
}
