.cp-page {
  --cp-ink: #24232b; --cp-muted: #666574; --cp-line: #e6e5eb;
  --cp-violet: #454095; --cp-lilac: #f1f0fb; --cp-gold: #78591e;
  display: grid; gap: 14px; color: var(--cp-ink); min-width: 0;
  font-size: 14px; line-height: 1.55; letter-spacing: 0;
}
.cp-page *, .cp-page *::before, .cp-page *::after { box-sizing: border-box; }
.cp-page :is(h2,h3,p) { margin: 0; }
.cp-page button { font: inherit; color: inherit; cursor: pointer; }
.cp-page button:focus-visible { outline: 3px solid #837ec6; outline-offset: 2px; }
.cp-card, .cp-birth { min-width: 0; overflow: hidden; background: #fff; border: 1px solid var(--cp-line); border-radius: 12px; }
.cp-card { padding: 14px; }
.cp-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 14px; }
.cp-heading h2 { display: inline-flex; align-items: center; gap: 8px; font-size: 16px; line-height: 1.4; font-weight: 710; }
.cp-heading h2::before { content: ''; width: 4px; height: 15px; background: var(--cp-violet); border-radius: 3px; flex: none; }
.cp-heading > span { color: var(--cp-muted); font-size: 11px; text-align: right; }
.cp-birth-primary, .cp-birth-facts, .cp-birth-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding-inline: 14px; }
.cp-birth-primary { padding-top: 13px; }
.cp-birth-primary strong { font-size: clamp(13px, 3.5vw, 16px); }
.cp-birth-primary strong span { white-space: nowrap; font-variant-numeric: tabular-nums; }
.cp-seal, .cp-tiny-tag { border-radius: 5px; padding: 2px 6px; font-size: 11px; }
.cp-seal { color: var(--cp-violet); background: #e9e7fb; }
.cp-tiny-tag { color: var(--cp-gold); background: #f9efdb; }
.cp-birth-facts { padding-block: 9px 12px; color: var(--cp-muted); gap: 6px 16px; font-size: 12px; }
.cp-birth-facts b, .cp-matrix-foot b { color: var(--cp-ink); font-weight: 560; }
.cp-birth-foot { padding-block: 8px; justify-content: space-between; border-top: 1px solid var(--cp-line); background: #f8f7fa; color: var(--cp-muted); font-size: 11px; }
.ce-wood { --ce: #367052; } .ce-fire { --ce: #ae5147; } .ce-earth { --ce: #866328; } .ce-metal { --ce: #514ca1; } .ce-water { --ce: #346887; }
.cp-page [class*="ce-"] { color: var(--ce); }
.cp-legend { display: inline-flex; align-items: center; gap: 3px; white-space: nowrap; }
.cp-legend i { font-style: normal; font-size: 8px; }
.cp-matrix { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 5px; }
.cp-pillar { display: grid; grid-template-rows: 34px 26px 73px 73px 97px repeat(3,46px); text-align: center; border: 1px solid var(--cp-line); border-radius: 7px; overflow: hidden; background: #fcfcfd; }
.cp-pillar.is-master { background: #f4f3fd; border-color: #c5c1e8; }
.cp-pillar > :not(:last-child) { border-bottom: 1px solid #e9e8ed; }
.cp-pillar-title, .cp-god { display:flex; align-items:center; justify-content:center; gap:3px; }
.cp-pillar-title { color: #55515f; background: #f4f3f6; font-size: 13px; }
.cp-pillar-title small { font-size: 9px; }
.is-master .cp-pillar-title { background: #e7e4fa; color: var(--cp-violet); }
.cp-god { color: var(--cp-muted); font-size: 11px; font-weight: 550; }
.is-master .cp-god { color: var(--cp-violet); }
.cp-large-char, .cp-mini-row, .cp-hidden { display: flex; flex-direction: column; align-items: center; justify-content: center; }
.cp-large-char { gap: 1px; }
.cp-large-char strong, .cp-season b, .cp-compare strong,.cp-months b, .cp-decades strong { font-family: "Songti SC","STSong","Noto Serif CJK SC","SimSun",serif; }
.cp-large-char strong { font-size: 35px; line-height: 1.15; font-weight: 620; }
.cp-page :is(.cp-large-char,.cp-mini-row,.cp-hidden) small { color: var(--cp-muted); font-size: 10px; }
.cp-hidden { justify-content: start; gap: 2px; padding-top: 7px; }
.cp-hidden span { font-size: 12px; color: var(--cp-ink); }
.cp-mini-row b { color: var(--cp-ink); font-size: 12px; font-weight: 560; }
.cp-matrix-foot { display: flex; align-items: center; justify-content: space-evenly; color: var(--cp-muted); font-size: 11px; padding-top: 10px; }
.cp-relations, .cp-deep { display: grid; gap: 8px; }
.cp-relations article { display:flex; align-items:flex-start; gap:10px; background:#faf9fb; border:1px solid #edecf1; border-radius:8px; padding:11px; }
.cp-relations article h3, .cp-deep h3, .cp-page .cp-subtitle h3 { font-size: 14px; line-height: 1.5; font-weight: 650; }
.cp-relations article small { font-size: 10px; color: var(--cp-muted); }
.cp-relations article p, .cp-deep p, .cp-dual p, .cp-analysis-summary p { margin-top: 4px; font-size: 12px; line-height: 1.7; color: #545260; }
.cp-rel-icon { display:grid;place-items:center;flex:0 0 31px;height:31px;border-radius:8px;background:color-mix(in srgb,var(--ce) 10%,white);font-family:"Songti SC","SimSun",serif;font-size:17px; }
.cp-analysis-summary { display:flex; align-items:center; gap:15px; justify-content:space-between; border:1px solid #dedcf1; background:var(--cp-lilac); padding: 12px; border-radius:8px; }
.cp-analysis-summary small { color:var(--cp-violet); font-size:11px; }
.cp-analysis-summary h3 { font-size:18px; color: #383482; margin-top:2px; }
.cp-season { flex:0 0 55px; height:55px; display:grid;align-content:center; justify-items:center; border:2px solid #d0cbe9; border-radius:50%; background:#fff; }
.cp-season b { font-size:22px; line-height:1.1;color:var(--cp-violet); } .cp-season small { font-size:9px; }
.cp-subtitle { display:flex; align-items:center; justify-content:space-between; gap:8px; margin:17px 0 8px; }
.cp-subtitle small { color:var(--cp-muted); font-size:11px; }
.cp-elements { display:grid; gap:6px; }
.cp-element { display:grid; grid-template-columns: 22px 1fr 35px; gap:8px; align-items:center; }
.cp-element b { font-size:12px; } .cp-element > span:last-child { color:var(--cp-muted); font-size:11px; text-align:right; }
.cp-track { height:6px; border-radius:5px; background:#f0eff3;overflow:hidden; }
.cp-track i { height:100%;border-radius:5px;background:var(--ce);display:block; }
.cp-page .cp-note { margin:10px 0 0; font-size:11px; line-height:1.6;color:var(--cp-muted); }
.cp-dual { display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:12px; }
.cp-dual > div { border:1px solid #ece7dc;background:#fbf9f4;padding:10px;border-radius:7px; }
.cp-dual > div:last-child { background:#f8f7fb;border-color:#e9e7f3; }
.cp-dual h3 { color:var(--cp-gold);font-size:13px; }
.cp-dual > div:last-child h3 { color:var(--cp-violet); }
.cp-instant { display:flex; align-items:center;justify-content:space-between;gap:6px;flex-wrap:wrap;padding:8px 10px;background:#f6f5f2;border:1px solid #e9e6df;border-radius:6px; }
.cp-instant span,.cp-instant b { font-size:11px; } .cp-instant span {color:var(--cp-muted);}
.cp-decades { position:relative; display:flex;gap:6px;overflow-x:auto;padding:3px 2px 8px;scrollbar-width:thin;scrollbar-color:#d4d0df transparent; }
.cp-decades button { flex:0 0 92px; min-height:77px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:2px; border:1px solid var(--cp-line); background:#fbfafc; border-radius:7px; }
.cp-decades button strong { font-size:22px; line-height:1.25; }
.cp-decades button small,.cp-decades button span { color:var(--cp-muted);font-size:10px;white-space:nowrap; }
.cp-decades button[aria-pressed=true], .cp-years button[aria-pressed=true] { background:var(--cp-lilac); border-color:#a9a4d7; color:#3f398a; }
.cp-decades button[aria-pressed=true] :is(small,span), .cp-years button[aria-pressed=true] span { color:#514a94; }
.cp-years { display:grid;grid-template-columns: repeat(5,minmax(0,1fr)); gap:6px;}
.cp-years button { display:flex; flex-direction:column; align-items:center;justify-content:center; min-height:47px;border:1px solid var(--cp-line);border-radius:6px;background:#fbfafc; }
.cp-years button b { font-size:12px;font-variant-numeric:tabular-nums; }
.cp-years button span { font-size:11px;color:var(--cp-muted); }
.cp-birth-foot [data-jump-transits] {margin-left:auto;padding:7px 1px;color:var(--cp-violet);background:none;font-size:12px;font-weight:620}
.cp-transits {scroll-margin-top:76px}
.cp-transits:focus-visible,.cp-compare:focus-visible {outline:2px solid var(--cp-violet);outline-offset:2px}
.cp-transits .cp-subtitle h3 {font-size:14px}
.cp-transits .cp-ask {margin-top:13px}
.cp-months {display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:5px}
.cp-months button {display:grid;justify-items:center;align-content:center;min-height:47px;padding:3px 1px;border:1px solid var(--cp-line);background:#fbfafc;border-radius:6px}
.cp-months button b {font-size:15px;line-height:1.3}
.cp-months button small {font-size:10px;color:var(--cp-muted)}
.cp-months button[aria-pressed="true"] {border-color:var(--cp-violet);box-shadow:inset 0 0 0 .5px var(--cp-violet);background:var(--cp-lilac);color:var(--cp-violet)}
.cp-months button[aria-pressed="true"] small {color:var(--cp-violet)}
.cp-month-window {display:grid;grid-template-columns:1fr auto;gap:2px 6px;margin:10px 0;padding:8px 11px;border-left:2px solid #aaa4d3;background:#f7f6fb;font-size:12px}
.cp-month-window b {color:var(--cp-violet);font-weight:620}
.cp-month-window span {color:var(--cp-muted);font-size:10px}
.cp-month-window p {grid-column:1/-1;color:#565060;line-height:1.55;font-variant-numeric:tabular-nums}
.cp-month-window time {white-space:nowrap}
.cp-compare {width:100%;overflow-x:auto;overscroll-behavior-x:contain;border:1px solid var(--cp-line);border-radius:7px;scrollbar-width:thin;scrollbar-color:#c6c1d4 transparent}
.cp-compare table {width:100%;min-width:546px;table-layout:fixed;border-collapse:separate;border-spacing:0;text-align:center;font-size:12px}
.cp-compare :is(th,td) {padding:5px 2px;vertical-align:middle;border-bottom:1px solid var(--cp-line);white-space:nowrap}
.cp-compare tr:last-child td,.cp-compare tbody tr:last-child th {border-bottom:0}
.cp-compare th {font-weight:580}
.cp-compare thead th {background:#f5f4f7;color:#554f5e}
.cp-compare thead th:nth-child(-n+4):not(:first-child) {background:#ece9f8;color:var(--cp-violet)}
.cp-compare tr>:first-child {position:sticky;left:0;width:43px;background:#fbfafc;border-right:1px solid var(--cp-line);color:var(--cp-muted);font-size:11px}
.cp-compare tr>:nth-child(2) {background:#f7f6fc}
.cp-compare tr>:nth-child(5) {border-left:1px solid #d8d4e1}
.cp-compare td strong {font-size:23px;line-height:1.1}
.cp-compare .cp-hidden-stem {display:block;font-size:11px;line-height:1.6}
.cp-compare .cp-hidden-stem b {font-weight:600}
@media(min-width:640px){.cp-swipe-cue {display:none}}
@media(max-width:370px){.cp-months {grid-template-columns:repeat(4,minmax(0,1fr))}}
.cp-comparison-notes p { font-size:12px;margin-top:9px;color:#514f5a; }
.cp-comparison-notes b { margin-right:6px;color:var(--cp-violet); }
.cp-deep article { border:1px solid var(--cp-line);padding:11px;border-radius:8px; }
.cp-deep article > header { display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:6px; }
.cp-deep article h4 {margin:0;font-size:13px;line-height:1.6;font-weight:600;color:var(--cp-muted);}
.cp-deep article b {font-size:10px;font-weight:550;color:var(--cp-gold);background:#fbf2df;padding:1px 6px;border-radius:6px;}
.cp-ask {display:flex;align-items:center;gap:10px;width:100%;padding:13px 14px;border:1px solid #ccc9e6;background:#eeecfb;color:var(--cp-violet)!important;border-radius:10px;text-align:left;}
.cp-ask > span:nth-child(2) {flex:1;display:grid;}
.cp-ask strong {font-size:14px;}.cp-ask small {color:#66617c;font-size:11px;}
.cp-ask-icon {display:grid;place-items:center;width:32px;height:32px;background:var(--cp-violet);border-radius:9px;color:white;font-size:19px;}
@media (min-width: 660px) {
  .cp-card { padding: 18px; }
  .cp-relations {grid-template-columns:1fr 1fr;}
  .cp-page {gap:16px;}
}
@media (max-width: 370px) {
  .cp-card {padding:10px;} .cp-heading h2 {font-size:14px;} .cp-pillar-title small {display:none;}
  .cp-legend {gap:2px;} .cp-pillar-title {font-size:12px;}
}

.cp-birth-nayin { margin-inline-start:auto; color:var(--cp-gold); font-size:11px; }
.cp-pillar { grid-template-rows:34px 26px 73px 73px 97px repeat(3,46px) minmax(94px,auto); }
.cp-hidden sup { font-family:inherit; color:#787384; font-size:8px; margin-left:1px; }
.cp-stars { display:flex;flex-direction:column;align-items:center;gap:2px;padding:5px 2px; }
.cp-stars small { font-size:10px;color:var(--cp-muted); }
.cp-stars span { color:#695224;background:#f5f0e4;padding:0 4px;border-radius:3px;font-size:10px;line-height:15px; }
.cp-stars em { font-size:11px;color:var(--cp-muted); }
.cp-rule { font-size:11px; color:var(--cp-muted); margin-top:8px; padding:5px 1px; }
.cp-rule h3 { color:var(--cp-ink); font-size:14px; line-height:1.5; font-weight:650; }
.cp-rule p { margin-top:5px; }
.cp-rule > div { margin-top:8px; }
.cp-rule > div b { color:var(--cp-ink); }
.cp-rule p strong { font-weight:550; }
.cp-element { grid-template-columns:17px 28px 1fr 35px; }
.cp-element small { color:var(--cp-muted); font-size:10px; }
.cp-years button { padding:4px 0; min-height:62px; }
.cp-years button small { color:var(--cp-muted); font-size:9px; line-height:1.3; }
.cp-decades button { min-height:85px; }
.cp-deep p strong { color:#474155; font-weight:600; }
