@charset "UTF-8";
.recovery-code {
  min-height: 100px;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  line-height: 1.7;
  letter-spacing: .04em;
  overflow-wrap: anywhere;
  resize: vertical;
  user-select: text;
}
[data-action="account-code-done"] {
  margin-top: 16px;
}
.auth-screen > .detail-head {
  margin-bottom: 24px;
}
.gua-triptych {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  text-align: center;
  margin-bottom: 20px;
}
.gua-triptych h2 {
  font-size: 16px;
  margin: 12px -4px;
}
.gua-triptych .mini-hex {
  max-width: 88px;
  margin: 0 auto 12px;
}
.gua-triptych small {
  font-size: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2px;
}
.gua-triptych .pill {
  padding: 4px 9px;
}
.six-element {
  font-size: 11px;
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  padding: 1px 4px;
  border-radius: 6px;
  background: var(--surface-edf4ee, #edf4ee);
}
.six-structure {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  font-size: 12px;
}
.six-relations {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 5px;
  margin: 16px 0 12px;
}
.six-relations > div {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
}
.six-relations small {
  font-size: 10px;
  white-space: nowrap;
}
.six-relations strong {
  font-size: 22px;
}
.six-relation {
  font-size: 11px;
  border-radius: 6px;
  padding: 3px 7px;
  white-space: nowrap;
}
.six-relation.support {
  background: var(--surface-edf7ef, #edf7ef);
  color: var(--text-24905a, #24905a);
}
.six-relation.caution {
  background: var(--surface-fff5e9, #fff5e9);
  color: var(--text-d85e39, #d85e39);
}
.six-relation.neutral {
  color: var(--muted);
}
.six-body-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  text-align: center;
}
.six-body-meta > div {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
}
.six-body-meta > div + div {
  border-left: 1px solid var(--line);
}
.six-body-meta strong {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 24px;
}
.six-body-meta span {
  font-size: 12px;
}
.six-lines .yao-table-header,
.six-lines .yao-table-row {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr) minmax(38px, 1.15fr) minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 3px 4px;
}
.six-lines .yao-table-row {
  min-height: 64px;
  padding: 6px 0;
}
.six-lines .yao-table-row > [role="cell"] {
  min-width: 0;
}
.six-lines .six-term,
.six-lines .six-line-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 44px;
  padding: 2px 0;
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.six-lines .six-term:hover,
.six-lines .six-line-main:hover {
  background: var(--surface-edf7ef, #edf7ef);
}
.six-lines .six-term:focus-visible,
.six-lines .six-line-main:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 1px;
}
.six-lines .six-line-main {
  gap: 7px;
}
.six-lines .six-line-main .yao {
  width: 100%;
  max-width: 56px;
  height: 6px;
  gap: 5px;
}
.six-lines .six-line-main small,
.six-empty {
  color: var(--muted);
}
.six-lines .six-row-notes {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px 5px;
  text-align: left;
}
.six-lines .six-row-notes:has(.six-flags:empty):not(:has(.six-timing)) {
  display: none;
}
.six-timing {
  font-size: 10px;
  color: var(--muted);
}
.six-timing.changed {
  color: var(--text-d85e39, #d85e39);
}
.six-flags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 3px;
  min-height: 0;
}
.six-flags i {
  font-style: normal;
  font-size: 10px;
  line-height: 17px;
  padding: 0 4px;
  border-radius: 4px;
  color: var(--text-24905a, #24905a);
  background: var(--surface-edf7ef, #edf7ef);
}
.six-flags i.moving {
  color: var(--text-d85e39, #d85e39);
  background: var(--surface-fff5e9, #fff5e9);
}
.six-line-detail > .yao {
  max-width: 80px;
  margin: 0 auto;
}
.six-term-explanation {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.six-term-explanation h3 {
  margin: 4px 0 8px;
}
.six-term-explanation p {
  font-size: 14px;
  line-height: 1.8;
  overflow-wrap: anywhere;
}
.six-time {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  margin: 16px 0 22px;
  text-align: center;
}
.six-time > div {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.six-time small {
  font-size: 10px;
}
.six-time b {
  font-size: 18px;
}
.six-stars {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  text-align: center;
  margin: 18px 0;
}
.six-stars span {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.six-stars b {
  font-size: 13px;
}
.six-stars small {
  font-size: 11px;
}
.six-detail-tags {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin: 16px 0;
}
.strength-track .w-wood small,
.strength-track .w-fire small,
.strength-track .w-earth small,
.strength-track .w-metal small,
.strength-track .w-water small {
  color: inherit;
}
.daily-basis {
  margin: 15px 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.daily-basis > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  background: var(--surface-f5f8f3, #f5f8f3);
  border-radius: 12px;
  padding: 12px;
  font-size: 12px;
  line-height: 1.8;
}
.daily-basis strong {
  flex-shrink: 0;
  font-size: 13px;
  min-width: 40px;
  text-align: right;
}
.daily-basis .plus {
  color: var(--text-2b8b55, #2b8b55);
}
.daily-basis .minus {
  color: var(--text-c06a43, #c06a43);
}
.daily-basis .neutral {
  color: var(--text-879282, #879282);
  font-size: 11px;
}
.daily-basis-note {
  font-size: 11px !important;
  color: var(--text-81917f, #81917f);
}
:root {
  color-scheme: light;
  --green: #07b960;
  --deep: #075d38;
  --ink: #14231b;
  --muted: #5f6962;
  --bg: #f6faf7;
  --line: #e9efea;
  --mint: #eaf8ee;
  --orange: #ff8e51;
  --wood: #3ebc7c;
  --fire: #ff9163;
  --earth: #c48b63;
  --earth-ink: #96603d;
  --metal: #e3b63d;
  --metal-ink: #996700;
  --water: #69a4e8;
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", sans-serif;
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  color: var(--ink);
  background: var(--surface-edf2ef, #edf2ef);
  font-size: 15px;
  line-height: 1.5;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  color: inherit;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
a {
  color: inherit;
  text-decoration: none;
}
button {
  border: 0;
  background: none;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #0bbd6880;
  outline-offset: 3px;
}
button:active {
  transform: scale(0.98);
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: 28px;
  line-height: 1.3;
  letter-spacing: -1px;
}
h2 {
  font-size: 18px;
  letter-spacing: -0.5px;
}
h3 {
  font-size: 16px;
}
.muted,
small {
  color: var(--muted);
}
small {
  font-size: 12px;
}
.icon {
  width: 22px;
  height: 22px;
  display: inline-block;
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.app {
  width: min(100%, 460px);
  min-height: 100dvh;
  margin: 0 auto;
  background: var(--bg);
  padding: 0 18px 105px;
  position: relative;
  overflow-x: clip;
}
.desktop-note {
  display: none;
}
.topbar {
  height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 8px;
}
.topbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 0 0 auto;
}
.topbar-brand .wordmark {
  white-space: nowrap;
  flex: none;
}
.mingshu-entry {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 44px;
  padding: 0 10px;
  border: 1px solid var(--edge-dfede3, #dfede3);
  border-radius: 22px;
  background: var(--surface-eff8f2, #eff8f2);
  color: var(--deep, #075d38);
  font-size: 12px;
  line-height: 1.4;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
  transition: background .16s ease, transform .16s ease;
}
.mingshu-entry svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.mingshu-entry:focus-visible {
  outline: 2px solid var(--green, #07b960);
  outline-offset: 3px;
}
.mingshu-entry:active { transform: scale(.97); }
.topbar-home > .role-chip { min-width: 0; }
.topbar-home > .role-chip > span[translate] {
  min-width: 0;
  max-width: 84px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.topbar-home > .role-chip > .avatar,
.topbar-home > .role-chip > .icon { flex: none; }
@media (max-width: 380px) {
  .topbar-home { gap: 8px; }
  .topbar-brand { gap: 7px; }
  .mingshu-entry { padding: 0 8px; }
  .topbar-home > .role-chip { padding: 6px 8px; gap: 4px; }
  .topbar-home > .role-chip > span[translate] { max-width: 42px; }
}
@media (hover: hover) {
  .mingshu-entry:hover { background: var(--mint, #e7f8ed); }
}
@media (prefers-reduced-motion: reduce) {
  .mingshu-entry { transition: none; }
}

.wordmark {
  font-size: 27px;
  font-weight: 850;
  letter-spacing: -1px;
}
.brand-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: var(--green);
  border-radius: 50%;
  margin: 0 0 3px 3px;
}
.role-chip,
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--surface-eff8f2, #eff8f2);
  border: 1px solid var(--edge-dfede3, #dfede3);
  border-radius: 24px;
  padding: 6px 10px;
  min-height: 38px;
  font-size: 12px;
  white-space: nowrap;
}
.role-chip .icon {
  width: 14px;
  height: 14px;
}
.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--surface-d8f5c4, #d8f5c4);
  flex-shrink: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  position: relative;
  color: var(--text-175d3b, #175d3b);
  font-weight: 800;
  font-size: 20px;
}
.avatar img {
  position: absolute;
  width: 205%;
  max-width: none;
  left: 0;
  top: -3%;
}
.avatar.alt {
  background: var(--surface-fff0da, #fff0da);
}
.avatar.alt img {
  left: -105%;
}
.avatar.sm {
  width: 28px;
  height: 28px;
  font-size: 12px;
}
.avatar.lg {
  width: 70px;
  height: 70px;
  font-size: 30px;
}
.hero {
  margin: 0 0 20px;
}
.hero h1 {
  font-size: 31px;
  font-weight: 850;
  letter-spacing: -1.3px;
  position: relative;
}
.hero .accent {
  position: relative;
  z-index: 0;
}
.hero .accent:after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 8px;
  background: var(--surface-a5ec85, #a5ec85);
  z-index: -1;
  border-radius: 50%;
  transform: rotate(-2deg);
}
.hero p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
}
.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.left {
  display: flex;
  align-items: center;
  gap: 10px;
}
.stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 22px 0 10px;
}
.card {
  background: var(--surface-ffffff, white);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 17px;
  margin-bottom: 12px;
  box-shadow: 0 3px 14px #234c3610;
}
.card.green {
  background: linear-gradient(
    120deg,
    var(--surface-effbe9, #effbe9),
    var(--surface-fff, #fff)
  );
}
.card.no-pad {
  padding: 0;
  overflow: hidden;
}
.grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.grid2 > .card {
  min-width: 0;
}
.pill {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 9px;
  background: var(--surface-e7f8ed, #e7f8ed);
  color: var(--deep);
  font-size: 11px;
  gap: 4px;
  align-items: center;
}
.pill.gray {
  background: var(--surface-f3f5f4, #f3f5f4);
  color: var(--text-819087, #819087);
}
.pill.orange {
  background: var(--surface-fff1e5, #fff1e5);
  color: var(--text-a95629, #a95629);
}
.pill.purple {
  background: var(--surface-f1edff, #f1edff);
  color: var(--text-7554aa, #7554aa);
}
.tiny-button {
  min-height: 32px;
  border-radius: 20px;
  background: var(--green);
  color: var(--text-ffffff, white);
  padding: 5px 12px;
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}
.tiny-button .icon {
  width: 14px;
  height: 14px;
}
.primary {
  min-height: 48px;
  border-radius: 25px;
  background: var(--green);
  color: var(--text-ffffff, white);
  font-weight: 650;
  padding: 12px 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.primary.dark {
  background: var(--surface-13251a, #13251a);
}
.primary.wide,
.secondary.wide {
  width: 100%;
}
.secondary {
  min-height: 44px;
  border-radius: 20px;
  background: var(--surface-ffffff, white);
  border: 1px solid var(--line);
  padding: 10px 14px;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}
.link {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  color: var(--deep);
  font-size: 13px;
  gap: 5px;
}
.link .icon {
  width: 16px;
  height: 16px;
}
.daily-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 16px 0 13px;
}
.daily-metric {
  border-radius: 14px;
  background: var(--surface-f0f8f2, #f0f8f2);
  padding: 12px 4px 9px;
  text-align: center;
  min-width: 0;
}
.daily-metric:nth-child(2) {
  background: var(--surface-fff6ed, #fff6ed);
}
.daily-metric:nth-child(3) {
  background: var(--surface-f2f1fb, #f2f1fb);
}
.daily-metric:nth-child(4) {
  background: var(--surface-eff6fd, #eff6fd);
}
.daily-metric .icon {
  color: var(--green);
  width: 22px;
  height: 22px;
}
.daily-metric span {
  display: block;
  font-size: 12px;
  margin: 4px 0 6px;
}
.daily-model-label {
  font-size: 12px;
  color: var(--muted);
}
.daily-index {
  display: block;
  font-size: 23px;
  line-height: 1.3;
  font-variant-numeric: tabular-nums;
}
.daily-meter {
  height: 5px;
  margin: 8px 10px;
  border-radius: 4px;
  overflow: hidden;
  background: var(--line);
}
.daily-meter b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
}
.daily-metric small {
  display: block;
  min-height: 2.8em;
  padding: 0 2px;
  font-size: 12px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.daily-meter.is-unscored {
  background: repeating-linear-gradient(90deg, var(--line) 0 5px, transparent 5px 9px);
}
.daily-detail-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 8px 0 14px;
}
.daily-detail-heading small {
  color: var(--muted);
}
.daily-detail-heading h2 {
  margin: 5px 0 0;
}
.daily-detail-heading > strong {
  color: var(--green);
  font-size: 32px;
  font-variant-numeric: tabular-nums;
}
.daily-theme summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  min-height: 44px;
}
.daily-theme-status {
  margin-left: auto;
  color: var(--muted);
  font-size: 12px;
}
.daily-theme-gods {
  color: var(--muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}
.daily-theme p, .daily-method p {
  line-height: 1.8;
}
.daily-basis > div > span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.daily-caption {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface-f0f7f2, #f0f7f2);
  border-radius: 14px;
  padding: 8px 10px;
  font-size: 12px;
  color: var(--text-435e4c, #435e4c);
}
.almanac {
  display: flex;
  gap: 14px;
  margin-top: 14px;
}
.almanac > div {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  flex: 1;
  min-width: 0;
  font-size: 13px;
}
.alm-summary-terms {
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 5px 10px;
  min-width: 0;
  padding-top: 4px;
}
.alm-summary-terms > span {
  max-width: 100%;
  word-break: keep-all;
  overflow-wrap: break-word;
}
.badge {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  background: var(--surface-dff5e8, #dff5e8);
  color: var(--text-14794a, #14794a);
  font-weight: 700;
}
.badge.ji {
  background: var(--surface-ffecdc, #ffecdc);
  color: var(--text-ca7043, #ca7043);
}
.tool-card {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  width: 100%;
  text-align: left;
  padding: 15px 14px;
  border-radius: 20px;
  background: var(--surface-ffffff, white);
  border: 1px solid var(--line);
  min-height: 138px;
  overflow: hidden;
}
.tool-card.green {
  background: var(--surface-edfae8, #edfae8);
}
.tool-card.orange {
  background: var(--surface-fff4eb, #fff4eb);
}
.tool-card small {
  display: block;
  margin: 2px 0 12px;
  font-size: 12px;
}
.tool-card > .pillars,
.tool-card > .zi-preview {
  margin: 0;
}
.bazi-use-preview {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px 8px;
  margin: 9px 0 0;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  line-height: 1.4;
}
.bazi-use-preview > div {
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
}
.bazi-use-preview > div:last-child {
  grid-column: 1 / -1;
}
.bazi-use-preview dt {
  flex: none;
  color: var(--muted);
  font-size: 11px;
}
.bazi-use-preview dd {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 5px;
  margin: 0;
  min-width: 0;
}
.pillars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  text-align: center;
  margin: 10px 0 0;
}
.pillars > div {
  min-width: 0;
}
.pillars b {
  font-size: 25px;
  font-weight: 650;
  display: block;
  line-height: 1.4;
}
.pillars span {
  display: block;
  font-size: 11px;
  color: var(--muted);
}
.pillars.compact b {
  font-size: 20px;
}
.w-wood,
.six-lines .yao-table-row .w-wood {
  color: var(--text-24905a, #24905a);
}
.w-fire,
.six-lines .yao-table-row .w-fire {
  color: var(--text-d85e39, #d85e39);
}
.w-earth,
.six-lines .yao-table-row .w-earth {
  color: var(--earth-ink);
}
.w-metal,
.six-lines .yao-table-row .w-metal {
  color: var(--metal-ink);
}
.w-water,
.six-lines .yao-table-row .w-water {
  color: var(--text-4b7cb9, #4b7cb9);
}
.mini-zw {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 3px;
}
.mini-zw span {
  border-radius: 4px;
  background: var(--surface-edf4ee, #edf4ee);
  padding: 4px 1px;
  font-size: 9px;
  text-align: center;
}
.pair-banner {
  position: relative;
  min-height: 152px;
  overflow: hidden;
  background: linear-gradient(
    110deg,
    var(--surface-fffaf0, #fffaf0),
    var(--surface-edfae8, #edfae8)
  );
  padding: 20px 17px;
  margin-top: 12px;
}
.pair-banner p {
  font-size: 12px;
  color: var(--text-718076, #718076);
  margin: 5px 0 15px;
  max-width: 180px;
}
.pair-banner img {
  position: absolute;
  width: 170px;
  right: -6px;
  bottom: 2px;
  pointer-events: none;
}
.pair-banner .copy {
  position: relative;
  z-index: 1;
  max-width: 57%;
}
.pair-banner h2 {
  font-size: 19px;
}
.tool-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: left;
  width: 100%;
  min-height: 78px;
}
.tool-row .icon {
  width: 30px;
  height: 30px;
  color: var(--text-718a78, #718a78);
}
.tool-row small {
  display: block;
  margin-top: 2px;
}
.list-row {
  width: 100%;
  min-height: 65px;
  padding: 12px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-align: left;
  gap: 10px;
  border-bottom: 1px solid var(--line);
}
.list-row:last-child {
  border: 0;
}
.list-row .icon {
  width: 18px;
  height: 18px;
  color: var(--text-7b8e81, #7b8e81);
}
.list-row small {
  display: block;
}
.list-row strong {
  font-size: 14px;
}
.nav {
  position: fixed;
  bottom: 0;
  z-index: 30;
  width: min(100%, 460px);
  left: 50%;
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: var(--surface-ffffffed, #ffffffed);
  backdrop-filter: blur(18px);
  border-top: 1px solid var(--line);
  padding: 9px 10px max(9px, env(safe-area-inset-bottom));
  height: 80px;
}
.nav button {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 3px;
  font-size: 10px;
  color: var(--text-7b8983, #7b8983);
  min-height: 55px;
  border-radius: 14px;
}
.nav .active {
  color: var(--green);
  font-weight: 700;
}
.nav .ai-orb {
  height: 49px;
  width: 49px;
  border-radius: 50%;
  background: var(--green);
  color: var(--text-ffffff, white);
  display: grid;
  place-items: center;
  font-size: 20px;
  font-weight: 750;
  box-shadow: 0 4px 12px #0bb96825;
}
.nav .icon {
  width: 23px;
  height: 23px;
}
.preview-strip {
  font-size: 11px;
  color: var(--text-829286, #829286);
  text-align: center;
  padding: 11px 0 0;
}
.profile-card .meta {
  font-size: 12px;
  color: var(--text-6c7e73, #6c7e73);
  margin-top: 5px;
}
.profile-card .row {
  align-items: flex-start;
}
.profile-card h2 {
  font-size: 20px;
}
.bars {
  margin-top: 15px;
  display: grid;
  gap: 11px;
}
.bar-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
}
.bar-row > span {
  width: 14px;
}
.bar-row > small {
  width: 32px;
  text-align: right;
}
.bar-track {
  height: 10px;
  flex: 1;
  border-radius: 6px;
  background: var(--surface-f0f3f1, #f0f3f1);
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  border-radius: 6px;
}
.duo-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-top: 18px;
}
.duo-actions button {
  border-radius: 12px;
  background: var(--surface-e9f8ed, #e9f8ed);
  padding: 10px 5px;
  color: var(--text-077a43, #077a43);
  font-size: 13px;
}
.duo-actions button:last-child {
  background: var(--surface-f0edfb, #f0edfb);
  color: var(--text-7552a2, #7552a2);
}
.role-pair {
  display: grid;
  grid-template-columns: 1fr 40px 1fr;
  align-items: center;
  gap: 10px;
  margin: 5px 0 18px;
}
.role-tile {
  display: flex;
  align-items: center;
  flex-direction: column;
  background: var(--surface-ffffff, white);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 18px 10px;
  gap: 8px;
  text-align: center;
  min-width: 0;
}
.role-tile strong {
  font-size: 16px;
}
.segmented {
  display: flex;
  background: var(--surface-edf1ee, #edf1ee);
  border-radius: 24px;
  padding: 4px;
  gap: 3px;
  overflow: auto;
  scrollbar-width: none;
}
.segmented button {
  padding: 8px 14px;
  min-height: 36px;
  font-size: 12px;
  border-radius: 20px;
  white-space: nowrap;
  flex: 1;
}
.segmented .selected {
  background: var(--green);
  color: var(--text-ffffff, white);
}
.compare-row {
  display: grid;
  grid-template-columns: 1fr 20px 1fr;
  gap: 12px;
  align-items: center;
  margin: 16px 0;
}
.compare-row .bar-track {
  height: 12px;
}
.compare-row .bar-track:first-child {
  transform: rotate(180deg);
}
.compare-row > span {
  text-align: center;
  font-size: 12px;
}
.empty {
  padding: 35px 15px;
  text-align: center;
}
.empty img {
  width: 165px;
  max-height: 135px;
  object-fit: contain;
  margin-bottom: 15px;
}
.empty h2 {
  font-size: 19px;
  margin: 0 0 9px;
}
.empty p {
  font-size: 13px;
  color: var(--text-7a8b80, #7a8b80);
  margin: 0 auto 18px;
  max-width: 270px;
}
.empty.compact {
  padding: 15px 0;
}
.detail-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 12px 0 20px;
}
.back {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--surface-ffffff, white);
  border: 1px solid var(--line);
}
.detail-head h1 {
  font-size: 22px;
}
.details {
  margin-top: 12px;
}
.details summary {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--text-718075, #718075);
  font-size: 12px;
  cursor: pointer;
}
.details summary:after {
  content: "＋";
}
.details[open] summary:after {
  content: "−";
}
.details p,
.details li {
  font-size: 12px;
  line-height: 1.8;
  color: var(--text-617367, #617367);
  margin-bottom: 8px;
}
.details ul {
  padding-left: 18px;
}
.timeline {
  display: flex;
  gap: 8px;
  overflow: auto;
  padding: 14px 0;
}
.time-item {
  padding: 12px 10px;
  min-width: 73px;
  text-align: center;
  background: var(--surface-f1f7f2, #f1f7f2);
  border-radius: 12px;
}
.time-item strong {
  display: block;
  font-size: 17px;
}
.time-item small {
  display: block;
  font-size: 10px;
  margin-top: 4px;
}
.chart-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, 100px);
  gap: 5px;
  margin: 14px 0;
}
.palace {
  background: var(--surface-ffffff, white);
  border: 1px solid var(--line);
  border-radius: 12px;
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  padding: 8px 6px;
  text-align: left;
  overflow: hidden;
  font-size: 11px;
}
.palace.active {
  background: var(--surface-e7f8ec, #e7f8ec);
  border-color: var(--edge-8cdaa7, #8cdaa7);
}
.palace.related {
  background: var(--surface-f3f9ee, #f3f9ee);
}
.palace strong {
  font-size: 12px;
}
.palace small {
  font-size: 10px;
  margin-top: 4px;
  color: var(--text-64816c, #64816c);
}
.chart-center {
  grid-column: 2/4;
  grid-row: 2/4;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  background: var(--surface-ecf7ef, #ecf7ef);
  border-radius: 20px;
  font-size: 13px;
  gap: 5px;
}
.chart-center h2 {
  font-size: 25px;
}
.chart-center img {
  width: 105px;
}
.chat {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 50dvh;
  padding: 15px 0 90px;
}
.bubble {
  border-radius: 20px;
  padding: 15px;
  max-width: 95%;
  font-size: 14px;
  line-height: 1.8;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.bubble.user {
  align-self: flex-end;
  background: var(--surface-ddf5e5, #ddf5e5);
  border-bottom-right-radius: 5px;
}
.bubble.assistant {
  align-self: flex-start;
  background: var(--surface-ffffff, white);
  border: 1px solid var(--line);
  border-bottom-left-radius: 5px;
}
.chat-intro {
  text-align: center;
  padding: 25px 5px 12px;
}
.chat-intro h2 {
  font-size: 25px;
}
.chat-intro img {
  width: 180px;
  height: 130px;
  object-fit: contain;
}
.suggestions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 20px;
}
.suggestions button {
  text-align: left;
  font-size: 13px;
  border: 1px solid var(--line);
  background: var(--surface-ffffff, white);
  border-radius: 14px;
  padding: 13px;
}
.composer {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  width: min(100%, 460px);
  display: flex;
  gap: 8px;
  background: var(--surface-f8fbf9f2, #f8fbf9f2);
  padding: 10px 16px;
  z-index: 25;
}
.composer textarea {
  flex: 1;
  resize: none;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 12px 16px;
  min-width: 0;
  background: var(--surface-ffffff, white);
  height: 48px;
  max-height: 100px;
  outline: none;
}
.composer button {
  border-radius: 50%;
  background: var(--green);
  color: var(--text-ffffff, white);
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
}
.notice {
  background: var(--surface-edf7ef, #edf7ef);
  border-radius: 13px;
  padding: 10px 12px;
  color: var(--text-52755e, #52755e);
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.notice.orange {
  background: var(--surface-fff3e8, #fff3e8);
  color: var(--text-9a643b, #9a643b);
}
.feed-card p {
  font-size: 14px;
  line-height: 1.8;
  margin-top: 13px;
}
.feed-card .actions {
  display: flex;
  gap: 14px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
  margin-top: 12px;
}
.feed-card .actions button {
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 5px;
  min-height: 32px;
  color: var(--text-708479, #708479);
}
.feed-card .actions .icon {
  width: 17px;
  height: 17px;
}
.floorplan {
  position: relative;
  height: 210px;
  border: 3px solid var(--edge-83a88e, #83a88e);
  margin: 16px 0;
  background: var(--surface-eff8ed, #eff8ed);
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 3px;
}
.floorplan div {
  border: 1px solid var(--edge-aac7b3, #aac7b3);
  display: grid;
  place-items: center;
  color: var(--text-5c7a66, #5c7a66);
  font-size: 13px;
}
.floorplan div:first-child {
  grid-row: 1/3;
}
.floorplan .north {
  position: absolute;
  top: -23px;
  left: 45%;
  border: 0;
  font-size: 11px;
}
.tool-frame {
  width: 100%;
  height: calc(100dvh - 175px);
  border: 0;
  border-radius: 15px;
  background: var(--surface-ffffff, white);
}
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: var(--surface-12241a65, #12241a65);
  backdrop-filter: blur(3px);
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.sheet {
  background: var(--surface-fff, #fff);
  border-radius: 26px 26px 0 0;
  width: min(100%, 460px);
  max-height: 92dvh;
  overflow: auto;
  padding: 8px 22px max(26px, env(safe-area-inset-bottom));
  box-shadow: 0 -8px 50px #173c2720;
}
.sheet:before {
  content: "";
  display: block;
  width: 35px;
  height: 4px;
  border-radius: 5px;
  background: var(--surface-dde6df, #dde6df);
  margin: 0 auto 15px;
}
.sheet-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 5px 0 18px;
}
.sheet-header h2 {
  font-size: 21px;
}
.sheet-header button {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--surface-f5f7f5, #f5f7f5);
  display: grid;
  place-items: center;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px;
}
.field {
  display: block;
  margin: 0 0 15px;
}
.field > span {
  display: block;
  font-size: 12px;
  color: var(--text-738579, #738579);
  margin-bottom: 7px;
}
.field input,
.field select,
.field textarea,
.search {
  background: var(--surface-f5f8f5, #f5f8f5);
  width: 100%;
  border: 1px solid var(--edge-e5eee7, #e5eee7);
  border-radius: 13px;
  padding: 13px 12px;
  min-height: 48px;
  min-width: 0;
  color: var(--ink);
}
.field textarea {
  min-height: 100px;
  resize: vertical;
}
.check-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 0;
  font-size: 14px;
}
.check-row input {
  accent-color: var(--green);
  width: 20px;
  height: 20px;
}
.error {
  color: var(--text-b63d30, #b63d30);
  font-size: 13px;
  padding: 10px 0;
}
.city-results {
  max-height: 180px;
  overflow: auto;
  border-radius: 12px;
  background: var(--surface-f8faf8, #f8faf8);
  margin-top: 4px;
}
.city-results button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  min-height: 43px;
}
.city-results small {
  display: block;
}
.date-display {
  background: var(--surface-f5f8f5, #f5f8f5);
  border-radius: 13px;
  padding: 12px;
  width: 100%;
  text-align: left;
  min-height: 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.wheels {
  position: relative;
  display: flex;
  height: 200px;
  margin: 20px 0;
  gap: 4px;
}
.wheels:before {
  content: "";
  position: absolute;
  top: 80px;
  height: 40px;
  left: 0;
  right: 0;
  background: var(--surface-edf7ef, #edf7ef);
  border-radius: 18px;
  pointer-events: none;
}
.wheel {
  flex: 1;
  overflow: auto;
  scroll-snap-type: y mandatory;
  scrollbar-width: none;
  padding: 80px 0;
  z-index: 1;
  min-width: 0;
  mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent);
}
.wheel button {
  display: block;
  width: 100%;
  height: 40px;
  scroll-snap-align: center;
  font-size: 20px;
  padding: 0;
}
.wheel button.selected {
  font-weight: 700;
  color: var(--deep);
}
.wheel-labels {
  display: flex;
  justify-content: space-around;
  font-size: 12px;
  color: var(--muted);
  margin-top: 18px;
}
#toast {
  position: fixed;
  bottom: 100px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  background: var(--surface-193b2bea, #193b2bea);
  color: var(--text-ffffff, white);
  padding: 12px 20px;
  border-radius: 15px;
  font-size: 13px;
  max-width: 90vw;
  display: none;
  box-shadow: 0 4px 20px #0002;
}
.loading {
  padding: 80px 20px;
  text-align: center;
  color: var(--text-6c8875, #6c8875);
}
.comment-list {
  margin-top: 12px;
}
.comment {
  padding: 12px 0;
  border-top: 1px solid var(--line);
  font-size: 13px;
}
.month-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 2px;
  margin: 16px -6px;
}
.month-grid button {
  padding: 6px 0;
  font-size: 9px;
  background: var(--surface-eff7f0, #eff7f0);
  border-radius: 5px;
  min-height: 48px;
}
.month-grid b {
  display: block;
  font-size: 11px;
}
.month-grid .selected {
  background: var(--surface-c5edce, #c5edce);
}
.status {
  border: 1px solid var(--line);
  padding: 8px 10px;
  border-radius: 12px;
  font-size: 11px;
  color: var(--text-77917e, #77917e);
  margin-top: 15px;
}
.footer-link {
  font-size: 11px;
  color: var(--text-84948a, #84948a);
  display: block;
  text-align: center;
  padding: 12px;
}
.full-panel {
  background: var(--surface-fff, #fff);
  border-radius: 16px;
  padding: 14px;
  margin: 14px 0;
}
.full-panel pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: 12px/1.7 inherit;
  color: var(--text-526d5b, #526d5b);
}
.profile-mini {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  gap: 10px;
  font-size: 12px;
}
.profile-mini strong {
  font-weight: 600;
}
.hexagram {
  display: flex;
  flex-direction: column-reverse;
  gap: 10px;
  margin: 25px auto;
  width: 145px;
}
.yao {
  display: flex;
  height: 12px;
  gap: 14px;
}
.yao span {
  flex: 1;
  background: var(--deep);
  border-radius: 3px;
}
.yao.moving span {
  background: var(--orange);
}
@media (min-width: 900px) {
  body {
    background: radial-gradient(
      ellipse at 30% 0%,
      var(--surface-e5f4e7, #e5f4e7),
      var(--surface-eef1ed, #eef1ed) 60%
    );
  }
  .app {
    margin-left: calc(50% + 65px);
    border-left: 1px solid var(--edge-dce7df, #dce7df);
    border-right: 1px solid var(--edge-dce7df, #dce7df);
    box-shadow: 0 0 70px #1f573510;
  }
  .nav,
  .composer {
    left: calc(50% + 295px);
  }
  .desktop-note {
    display: block;
    position: fixed;
    left: calc(50% - 390px);
    top: 12vh;
    width: 345px;
  }
  .desktop-note .wordmark {
    font-size: 32px;
  }
  .desktop-note h1 {
    font-size: 32px;
    line-height: 1.6;
    margin-top: 60px;
    letter-spacing: -1px;
  }
  .desktop-note p {
    color: var(--text-718678, #718678);
    line-height: 2;
    font-size: 15px;
    margin-top: 20px;
  }
  .preview-label {
    font-size: 11px;
    color: var(--text-7d9484, #7d9484);
    margin-top: 30px;
  }
  .desktop-friends {
    width: 270px;
    margin-top: 28px;
  }
  .sheet {
    border-radius: 26px;
    max-height: 85dvh;
    margin-bottom: 6vh;
  }
  .modal-backdrop {
    align-items: center;
  }
  .sheet:before {
    display: none;
  }
}
@media (max-width: 365px) {
  .app {
    padding-inline: 13px;
  }
  .hero h1 {
    font-size: 28px;
  }
  .pair-banner img {
    width: 145px;
  }
  .pair-banner h2 {
    font-size: 17px;
  }
  .chart-grid {
    grid-template-rows: repeat(4, 90px);
  }
  .role-chip {
    max-width: 165px;
    overflow: hidden;
  }
  .card {
    padding: 14px;
  }
  .grid2 {
    gap: 9px;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .card,
  .tool-card {
    animation: appear 0.23s ease-out;
  }
  @keyframes appear {
    from {
      opacity: 0.6;
      transform: translateY(3px);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }
}
.auth-screen {
  padding-bottom: 15px;
}
.auth-art {
  height: 190px;
  display: grid;
  place-items: center;
  background: radial-gradient(
    ellipse,
    var(--surface-e2f9c9, #e2f9c9) 0%,
    transparent 65%
  );
  margin: 5px 0 20px;
}
.auth-art img {
  height: 100%;
  max-width: 100%;
  object-fit: contain;
}
.auth-screen h1 {
  font-size: 29px;
}
.auth-intro {
  font-size: 13px;
  color: var(--text-708379, #708379);
  margin: 10px 0 24px;
}
.auth-tabs {
  margin-bottom: 22px;
}
.auth-tabs button {
  flex: 1;
  min-height: 44px;
}
.auth-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin: 26px 0;
  color: var(--text-94a199, #94a199);
  font-size: 11px;
}
.auth-steps .active {
  font-weight: 700;
  color: var(--deep);
}
.auth-steps i {
  display: block;
  width: 19px;
  height: 1px;
  background: var(--surface-d6e2da, #d6e2da);
}
.auth-note {
  display: block;
  text-align: center;
}
.onboard-hero {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 22px 0;
}
.onboard-hero h1 {
  font-size: 25px;
}
.onboard-hero p {
  color: var(--muted);
  font-size: 12px;
  margin-top: 5px;
}
#onboarding-fields {
  padding: 18px;
  background: var(--surface-fff, #fff);
  border: 1px solid var(--line);
  border-radius: 24px;
}
.points-card button {
  text-align: left;
}
.points-card h2 {
  font-size: 27px;
}
.points-card h2 small {
  font-weight: 400;
  font-size: 12px;
}
.points-card .icon {
  width: 13px;
  height: 13px;
  vertical-align: middle;
}
.points-card > small {
  display: block;
  margin-top: 9px;
  font-size: 11px;
}
.points-card .primary {
  font-size: 13px;
  min-height: 44px;
  padding: 10px 17px;
}
.div-subject {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-627b6b, #627b6b);
}
.div-subject > .link {
  margin-left: auto;
}
.div-hero {
  position: relative;
  display: flex;
  min-height: 176px;
  align-items: center;
  margin: 12px 0 15px;
  overflow: hidden;
}
.div-hero > div {
  position: relative;
  z-index: 1;
}
.div-hero h1 {
  font-size: 28px;
  line-height: 1.4;
}
.div-hero p {
  font-size: 11px;
  color: var(--text-778a7d, #778a7d);
  margin-top: 10px;
}
.div-hero .eyebrow {
  display: block;
  font-size: 8px;
  letter-spacing: 1.4px;
  color: var(--text-7fa18a, #7fa18a);
  margin-bottom: 9px;
}
.div-hero img {
  width: 170px;
  position: absolute;
  right: -29px;
  bottom: 8px;
  transform: rotate(-8deg);
}
.div-footnote {
  font-size: 11px;
  color: var(--text-788b7e, #788b7e);
  line-height: 1.7;
  text-align: center;
  margin: 12px 0;
}
.cast-modes {
  margin: 15px 0;
  display: flex;
}
.cast-modes button {
  flex: 1;
  padding: 11px 3px;
  font-size: 12px;
  min-height: 44px;
}
.coin-card {
  text-align: center;
}
.coin-stage {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin: 28px 0;
}
.coin-disc {
  width: 69px;
  height: 69px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 22px;
  color: var(--text-417146, #417146);
  background: var(--surface-d5f4b1, #d5f4b1);
  border: 6px solid var(--edge-b3de8c, #b3de8c);
  box-shadow:
    0 5px 0 #8eb65f,
    0 10px 18px #537c3820;
  transform: rotate(-10deg);
}
.coin-disc:nth-child(2) {
  transform: rotate(10deg) translateY(-6px);
}
.coin-disc.back {
  background: var(--surface-ffebcd, #ffebcd);
  border-color: var(--edge-ffd391, #ffd391);
  box-shadow: 0 5px 0 #d7ab63;
  color: var(--text-a26b30, #a26b30);
}
.throw-progress {
  display: flex;
  gap: 9px;
  justify-content: center;
  margin: 0 0 21px;
}
.throw-progress span {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--surface-f1f5f2, #f1f5f2);
  display: grid;
  place-items: center;
  color: var(--text-a3b3a8, #a3b3a8);
  font-size: 11px;
}
.throw-progress .done {
  background: var(--surface-dff4cc, #dff4cc);
  color: var(--text-466b36, #466b36);
  font-weight: bold;
}
.mini-hex {
  display: flex;
  flex-direction: column;
  gap: 7px;
  width: 100px;
  margin: 20px auto;
}
.mini-hex .yao {
  height: 8px;
  gap: 14px;
}
.empty-yao {
  opacity: 0.1;
}
.manual-yaos {
  margin: 18px 0;
}
.manual-yao {
  display: grid;
  grid-template-columns: 30px 1fr 125px;
  align-items: center;
  gap: 20px;
  margin: 10px 0;
}
.manual-yao select {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-f5f8f5, #f5f8f5);
  padding: 10px 6px;
  min-height: 44px;
  font-size: 12px;
  width: 100%;
}
.manual-yao .yao {
  height: 9px;
}
.qm-preview {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  width: 185px;
  margin: 22px auto;
  transform: none;
}
.qm-preview span {
  display: grid;
  place-items: center;
  height: 48px;
  background: var(--surface-eaf6e6, #eaf6e6);
  border: 1px solid var(--edge-dbe9d9, #dbe9d9);
  border-radius: 8px;
  color: var(--text-8aab88, #8aab88);
  font-size: 12px;
}
.qm-preview .center {
  background: var(--surface-c1ed9c, #c1ed9c);
  color: var(--text-426d38, #426d38);
  font-weight: 700;
}
.question-title {
  margin: 12px 0;
  font-size: 21px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.gua-pair {
  display: grid;
  grid-template-columns: 1fr 22px 1fr;
  gap: 8px;
  align-items: center;
  text-align: center;
}
.gua-pair h2 {
  font-size: 20px;
  margin: 12px 0;
}
.gua-arrow {
  font-size: 23px;
  color: var(--text-84a38f, #84a38f);
}
.yao-table-header,
.yao-table-row {
  display: grid;
  grid-template-columns: 39px 62px 1fr 24px 58px;
  align-items: center;
  gap: 6px;
  text-align: center;
  width: 100%;
}
.yao-table-header {
  font-size: 10px;
  color: var(--muted);
  margin-top: 18px;
  padding-bottom: 10px;
}
.yao-table-row {
  min-height: 63px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  padding: 7px 0;
}
.yao-table-row b {
  font-size: 12px;
  font-weight: 600;
  display: block;
}
.yao-table-row small {
  display: block;
  font-size: 10px;
}
.yao-table-row .yao {
  height: 8px;
  gap: 9px;
}
.line-badge {
  font-size: 11px;
  color: var(--text-399964, #399964);
}
.strength-track {
  display: flex;
  gap: 6px;
  margin: 15px 0;
}
.strength-track > span {
  flex: 1;
  border-radius: 12px;
  padding: 10px 4px;
  background: var(--surface-f0f7ee, #f0f7ee);
  text-align: center;
}
.strength-track b {
  display: block;
  font-size: 16px;
}
.strength-track small {
  font-size: 10px;
}
.qimen-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
  margin: 20px 0 7px;
  text-align: center;
  font-size: 10px;
  color: var(--muted);
}
.qimen-meta b {
  display: block;
  font-size: 14px;
  color: var(--text-285537, #285537);
  margin-top: 5px;
}
.qimen-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin-top: 15px;
}
.qimen-cell {
  min-width: 0;
  min-height: 167px;
  background: var(--surface-ffffff, white);
  border: 1px solid var(--edge-e1eadf, #e1eadf);
  border-radius: 15px;
  padding: 9px 8px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
  text-align: left;
}
.qimen-cell.selected {
  border: 2px solid var(--edge-09ad59, #09ad59);
  padding: 8px 7px;
  background: var(--surface-eef9e9, #eef9e9);
  box-shadow: 0 4px 12px #0e4b1910;
}
.qm-heading {
  font-size: 10px;
  color: var(--text-67806d, #67806d);
  display: flex;
  justify-content: space-between;
  gap: 1px;
}
.qm-heading > span {
  color: var(--text-94a398, #94a398);
  font-size: 9px;
}
.qm-god {
  font-size: 10px;
  color: var(--text-7a8e78, #7a8e78);
}
.qimen-cell strong {
  font-size: 19px;
  color: var(--text-194f33, #194f33);
  line-height: 1.2;
}
.qm-star {
  font-size: 11px;
  color: var(--text-587c51, #587c51);
  min-height: 16px;
}
.qimen-cell small {
  font-size: 9px;
}
.qm-badges {
  font-size: 9px;
  color: var(--text-c58142, #c58142);
  min-height: 13px;
}
.qimen-cell.center {
  justify-content: center;
  align-items: center;
  background: var(--surface-e2f2d6, #e2f2d6);
  text-align: center;
}
.qimen-cell.center strong {
  font-size: 21px;
  margin: 10px 0;
}
.palace-summary p {
  font-size: 13px;
  margin-top: 15px;
}
.ai-tool-card {
  margin-top: 20px;
  background: linear-gradient(
    130deg,
    var(--surface-edf9e5, #edf9e5),
    var(--surface-fff, #fff)
  );
}
.ai-tool-card .primary {
  margin-top: 18px;
}
.ai-tool-card h3 {
  font-size: 15px;
}
.ai-tool-card small {
  font-size: 11px;
}
.record-open {
  flex: 1;
  text-align: left;
  min-height: 44px;
}
.record-open strong,
.record-open small {
  display: block;
}
.record-open strong {
  font-size: 14px;
  overflow-wrap: anywhere;
}
.record-open small {
  margin-top: 4px;
}
.field input[type="datetime-local"] {
  min-width: 0;
  width: 100%;
  max-width: 100%;
  font-size: 14px;
}
.auth-screen .segmented {
  display: flex;
}
.auth-screen .segmented button {
  width: 50%;
}
@media (max-width: 365px) {
  .qimen-cell {
    padding: 8px 6px;
    min-height: 165px;
    gap: 7px;
  }
  .qimen-cell.selected {
    padding: 7px 5px;
  }
  .qimen-cell strong {
    font-size: 17px;
  }
  .yao-table-row,
  .yao-table-header {
    grid-template-columns: 33px 52px 1fr 20px 48px;
    gap: 4px;
  }
  .coin-disc {
    width: 60px;
    height: 60px;
  }
  .div-hero img {
    width: 150px;
    right: -35px;
  }
  .div-hero h1 {
    font-size: 26px;
  }
  .auth-art {
    height: 160px;
  }
}
.auth-art img {
  width: 280px;
  height: 180px;
  display: block;
  object-fit: contain;
}
.auth-art {
  overflow: hidden;
}
@media (max-width: 365px) {
  .auth-art img {
    height: 150px;
    width: 240px;
  }
}

[hidden] {
  display: none !important;
}
#onboarding-fields .form-grid {
  grid-template-columns: 1fr;
}

.house-tags {
  display: flex;
  gap: 7px;
  margin-top: 10px;
}

.pair-banner .pair-start {
  background: #20cf78;
  color: #073820;
  box-shadow: 0 4px 12px #20cf7820;
}
.pair-banner .pair-start:hover {
  background: #30db86;
}
.qm-badges{display:flex;flex-wrap:wrap;gap:3px;min-height:17px}
.qm-badges i{display:inline-flex;align-items:center;justify-content:center;min-width:16px;padding:1px 3px;border-radius:4px;background:var(--mint);color:var(--deep);font:inherit;font-style:normal}
.qm-term{display:block;min-height:36px;color:var(--deep);background:transparent;text-align:left;font-size:14px;font-weight:650;padding:5px 0;overflow-wrap:anywhere}
.qm-term:focus-visible{outline:2px solid var(--green);outline-offset:2px;border-radius:4px}
.qm-stem-detail{display:flex;gap:8px;flex-wrap:wrap;border-top:1px solid var(--line);padding:12px 0;font-size:12px;color:var(--muted)}
.qm-stem-detail span{flex:1;white-space:nowrap}.qm-stem-detail b{color:var(--ink)}
.qm-structures details{border-top:1px solid var(--line);padding:8px 0}.qm-structures summary{display:flex;align-items:center;justify-content:space-between;min-height:36px;cursor:pointer;color:var(--muted);font-size:11px}.qm-structures p{line-height:1.8;color:var(--muted);font-size:13px}
.qm-targets{display:grid;grid-template-columns:minmax(0,1fr) 22px minmax(0,1fr);gap:6px;margin:16px 0}
.qm-targets button{display:flex;flex-direction:column;gap:8px;align-items:center;border-radius:15px;padding:13px 7px;background:var(--mint);color:var(--ink);min-width:0}
.qm-targets small,.qm-targets span{font-size:11px;color:var(--muted)}.qm-targets strong{display:flex;align-items:center;gap:5px;flex-wrap:wrap;justify-content:center;font-size:15px}.qm-relation-link{align-self:center;text-align:center;color:var(--green)}
.qm-relation{display:flex;flex-direction:column;align-items:flex-start;font-size:12px;gap:6px}.qm-relation strong{font-size:14px}.palace-summary{scroll-margin-top:16px}
.qm-preview { transform:none; gap:6px; }
.qm-preview span { animation:qm-cell-glow 6s ease-in-out infinite; animation-delay:var(--qm-delay,0s); }
.qm-preview .center { animation:qm-center-breathe 3.2s ease-in-out infinite; }
@keyframes qm-cell-glow { 0%,12%,62%,100% { box-shadow:inset 0 0 0 0 transparent; } 32% { box-shadow:inset 0 0 0 2px color-mix(in srgb,var(--green) 45%,transparent),0 0 12px color-mix(in srgb,var(--green) 12%,transparent); border-color:color-mix(in srgb,var(--green) 50%,var(--line)); } }
@keyframes qm-center-breathe { 0%,100% { box-shadow:0 0 0 0 transparent; } 50% { box-shadow:0 0 0 5px color-mix(in srgb,var(--green) 12%,transparent),0 0 20px color-mix(in srgb,var(--green) 15%,transparent); } }
.qm-dun-preview { display:flex; align-items:center; gap:12px; padding:15px 12px; margin:8px 0; border:1px solid var(--line); border-radius:17px; background:var(--mint); }
.qm-dun-symbol { display:grid; place-items:center; width:42px; height:42px; flex-shrink:0; border-radius:15px; background:var(--surface-fff,#fff); color:var(--deep); font-size:27px; }
.qm-dun-preview.yang .qm-dun-symbol { color:var(--metal-ink,#b67b0e); }
.qm-dun-preview > div { flex:1; min-width:0; display:flex; flex-direction:column; gap:5px; }
.qm-dun-preview strong { font-size:18px; color:var(--deep); }
.qm-dun-preview small,.qm-dun-preview div>span { font-size:11px; color:var(--muted); }
.qm-dun-preview .pill { font-size:10px; flex-shrink:0; }
.qm-dun-note { font-size:11px; line-height:1.8; color:var(--muted); margin:9px 0 12px; }
@media(prefers-reduced-motion:reduce) { .qm-preview span,.qm-preview .center { animation:none; } }
