/* Vendor Tycoon 汉化版 —— 视觉 1:1 复刻原版 */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: #06070c; color: #1f1407;
  font-family: Georgia, "Times New Roman", "Songti SC", "SimSun", serif;
  -webkit-font-smoothing: antialiased;
}

.tycoon {
  --tycoon-ink: #1f1407;
  --tycoon-ink-soft: #4f3a1f;
  --tycoon-gold: #f3d37a;
  --tycoon-gold-dim: #9b710f;
  font-family: Georgia, "Times New Roman", "Songti SC", "SimSun", serif;
  color: var(--tycoon-ink);
}
.tycoon img { image-rendering: pixelated; }
/* 原版 Tailwind preflight：图片不得撑破容器，且按比例保持宽高比 */
.tycoon img, .tycoon video { max-width: 100%; height: auto; }
.tycoon img { display: block; vertical-align: middle; }
.tycoon-screen {
  position: fixed; inset: 0; z-index: 60;
  display: flex; justify-content: center; padding: 12px; background: #06070ceb;
}
.tycoon-window { display: flex; flex-direction: column; width: 100%; max-width: 1400px; height: 100%; }
.tycoon-window > .tycoon-inset { display: flex; flex: 1; flex-direction: column; min-height: 0; }

.tycoon-tablet { border: 44px solid transparent; border-image: url(../img/frame-tablet.png) 44 round; background: url(../img/fill-tablet.png) padding-box; }
.tycoon-parchment { border: 26px solid transparent; border-image: url(../img/frame-parchment.png) 26 round; background: url(../img/fill-parchment.png) padding-box; }
.tycoon-dark {
  border-style: solid; border-color: transparent; border-width: 18px 20px;
  border-image: url(../img/frame-dark.png) 18 20 round; background: url(../img/fill-dark.png) padding-box; color: var(--tycoon-gold);
}
.tycoon-scroll {
  border-style: solid; border-color: transparent; border-width: 38px 38px 48px;
  border-image: url(../img/frame-scroll.png) 38 38 48 round; background: url(../img/fill-scroll.png) padding-box;
}
.tycoon-tablet > .tycoon-inset { margin: -14px -20px; }
.tycoon-parchment > .tycoon-inset { margin: -14px; }
.tycoon-dark > .tycoon-inset { margin: -9px -10px; }
.tycoon-scroll > .tycoon-inset { margin: -8px -12px -14px; }

.tycoon-head { display: flex; flex: none; align-items: center; justify-content: space-between; gap: 8px; height: 32px; padding: 0 4px; white-space: nowrap; }
.tycoon-title {
  overflow: hidden; text-overflow: ellipsis; font-size: 1.5rem; font-weight: 700; letter-spacing: .5px;
  color: #1d1a16; text-shadow: 0 1px 0 rgba(255, 255, 255, .35);
}
.tycoon-status { min-width: 0; overflow: hidden; text-overflow: ellipsis; font-size: .875rem; }
.tycoon-update {
  display: flex; flex: none; flex-wrap: wrap; align-items: center; justify-content: center; gap: 4px 12px;
  margin-bottom: 4px; padding: 4px 8px; background: #4b3606; box-shadow: inset 0 0 0 1px var(--tycoon-gold-dim);
  color: #fff3c9; font-size: .875rem; font-weight: 700;
}

.tycoon-pursebar {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center;
  gap: 4px 12px; height: 56px; padding: 0 6px; white-space: nowrap;
}
.tycoon-pursebar > div { min-width: 0; }
.tycoon-purse {
  overflow: hidden; text-overflow: ellipsis; font-size: 1.75rem; font-weight: 700; line-height: 1.1;
  font-variant-numeric: tabular-nums; text-shadow: 1px 1px 0 #4b3004, 0 0 6px rgba(255, 205, 71, .25);
}
.tycoon-income { overflow: hidden; text-overflow: ellipsis; font-size: .9375rem; font-variant-numeric: tabular-nums; }
.tycoon-muted { color: var(--tycoon-ink-soft); }
.tycoon-dark .tycoon-muted { color: #b9a26a; }
.tycoon-num { font-variant-numeric: tabular-nums; }
.tycoon-buymodes { display: flex; align-items: center; gap: 4px; }

.tycoon-tabs { display: flex; flex: none; gap: 4px; height: 46px; padding: 8px 2px 0; overflow-x: auto; scrollbar-width: none; }
.tycoon-tabs::-webkit-scrollbar { display: none; }
.tycoon-tabs-end { margin-left: auto; }

.tycoon-body {
  flex: 1; min-height: 0; margin-top: 4px; overflow-y: auto;
  scrollbar-gutter: stable; scrollbar-width: thin; scrollbar-color: #4a4334 transparent;
}
.tycoon-foot { flex: none; padding: 6px 4px 0; font-size: .875rem; }

.tycoon-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 6px 12px 5px;
  background: linear-gradient(to bottom, #1c1a14, #090a08 55%, #050605); color: var(--tycoon-gold);
  border: 2px solid var(--tycoon-gold-dim); border-radius: 2px;
  box-shadow: 0 0 0 1px #2d2108, inset 0 0 0 1px #d3a92f, 2px 3px #00000080;
  font-family: inherit; font-size: .875rem; font-weight: 700; line-height: 1.15;
  white-space: nowrap; text-shadow: 1px 1px 0 #4b3004; cursor: pointer;
  transition: color .12s, border-color .12s, background .12s;
}
.tycoon-btn:hover:enabled { color: #ffe9a8; border-color: #c99a24; background: linear-gradient(to bottom, #2a2618, #11120e); }
.tycoon-btn:active:enabled { transform: translate(1px, 2px); box-shadow: 0 0 0 1px #2d2108, inset 0 0 0 1px #d3a92f; }
.tycoon-btn:disabled { color: #8d8674; border-color: #5d5647; box-shadow: 0 0 0 1px #24211b, inset 0 0 0 1px #6f6753; text-shadow: none; cursor: default; }
.tycoon-btn[aria-pressed="true"], .tycoon-btn[aria-pressed="true"]:hover:enabled {
  border-color: #e2b53a; background: linear-gradient(to bottom, #7a5a10, #4b3606); color: #fff3c9;
}
.tycoon-btn-wrap { max-width: 100%; white-space: normal; }
.tycoon-btn-small { padding: 3px 8px 2px; font-size: .75rem; }
.tycoon-btn-danger, .tycoon-btn-danger:hover:enabled {
  color: #fff1ec; border-color: #e0604a; background: linear-gradient(to bottom, #9c2a1a, #6a160b);
  box-shadow: 0 0 0 1px #2d0b05, inset 0 0 0 1px #f08a74, 2px 3px #00000080; text-shadow: 1px 1px 0 #3d0a03;
}
.tycoon-btn-danger:hover:enabled { background: linear-gradient(to bottom, #b8331f, #7e1b0e); }
.tycoon-btn-safe, .tycoon-btn-safe:hover:enabled {
  color: #eefbe8; border-color: #5fae4a; background: linear-gradient(to bottom, #2f7a22, #1a4a12);
  box-shadow: 0 0 0 1px #0b2406, inset 0 0 0 1px #8fd47a, 2px 3px #00000080; text-shadow: 1px 1px 0 #0d2a08;
}
.tycoon-btn-safe:hover:enabled { background: linear-gradient(to bottom, #389129, #205a16); }
.tycoon-tab { position: relative; flex: none; height: 32px; }
.tycoon-badge {
  position: absolute; top: -8px; right: -4px; z-index: 1; min-width: 1.15rem; padding: 0 4px;
  border-radius: 999px; background: #b3261e; box-shadow: 0 0 0 1px #2d0906;
  color: #fff; font-size: .7rem; line-height: 1.15rem; text-align: center; text-shadow: none;
}

.tycoon-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: minmax(118px, 1fr); gap: 8px; min-height: 100%;
}
.tycoon-card {
  display: flex; min-width: 0; user-select: none; -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent; position: relative;
}
.tycoon-card[data-idle] { cursor: pointer; outline: 3px solid rgba(255, 196, 0, 0); outline-offset: -3px; animation: tycoon-card-beckon 1.4s ease-in-out infinite; }
@keyframes tycoon-card-beckon { 50% { outline-color: #ffc400f2; background-color: #ffc40024; } }
.tycoon-locked:not([data-ready]) > .tycoon-inset { filter: grayscale(.9); opacity: .8; }
.tycoon-locked:not([data-ready]) .tycoon-buy { justify-content: center; background: #2b2924; border-color: #4a4539; box-shadow: none; }
.tycoon-locked[data-ready] .tycoon-art img { filter: none; opacity: 1; }
.tycoon-locked[data-ready] .tycoon-buy { animation: tycoon-ready 1.2s ease-in-out infinite; }
@keyframes tycoon-ready { 50% { box-shadow: 0 0 0 1px #2d2108, inset 0 0 0 1px #d3a92f, 0 0 10px 2px #ffc400e6; } }
.tycoon-card > .tycoon-inset { display: flex; flex: 1; align-items: center; gap: 12px; min-width: 0; }
.tycoon-card-main { flex: 1; min-width: 0; overflow: hidden; }
.tycoon-card-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; height: 26px; white-space: nowrap; }
.tycoon-card-name { overflow: hidden; text-overflow: ellipsis; font-size: 1.125rem; font-weight: 700; }
.tycoon-card-note { height: 22px; overflow: hidden; text-overflow: ellipsis; font-size: .9375rem; line-height: 22px; white-space: nowrap; }
.tycoon-buyrow { display: grid; grid-template-columns: minmax(0, 1fr) 9rem; align-items: center; gap: 6px 12px; margin-top: 8px; }
.tycoon-buy { justify-content: space-between; width: 100%; min-width: 0; height: 30px; overflow: hidden; font-variant-numeric: tabular-nums; }
.tycoon-buy > span:last-child { overflow: hidden; text-overflow: ellipsis; }
.tycoon-next { height: 14px; overflow: hidden; font-size: .75rem; font-weight: 700; line-height: 14px; text-align: right; white-space: nowrap; }

.tycoon-art {
  position: relative; display: flex; flex: none; align-items: center; justify-content: center;
  width: 92px; height: 92px; border: 0; border-radius: 50%;
  background: radial-gradient(circle, #4a341447, #4a341400 70%);
  /* .tycoon-art 是 <button>，浏览器默认给 1px 6px 内边距，
     会把 92px 的图标盒压到 80px，导致 img 被 max-width 挤扁。
     原版用 Tailwind preflight 把按钮内边距清零。 */
  padding: 0;
}
.tycoon-art:enabled { cursor: pointer; animation: tycoon-beckon 1.2s ease-in-out infinite; }
.tycoon-art:enabled:hover { animation: none; transform: scale(1.06); }
@keyframes tycoon-beckon { 0%, to { filter: drop-shadow(0 0 0 rgba(255, 196, 0, 0)); } 50% { filter: drop-shadow(0 0 7px rgba(255, 196, 0, .95)); } }
.tycoon-locked .tycoon-art img { filter: grayscale(1) brightness(.55); opacity: .7; }
.tycoon-owned {
  position: absolute; bottom: -4px; left: 50%; transform: translate(-50%); padding: 1px 9px 0;
  background: #0a0c0c; color: var(--tycoon-gold); border: 1px solid var(--tycoon-gold-dim);
  box-shadow: inset 0 0 0 1px #2b210d; font-size: .875rem; font-weight: 700;
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.tycoon-owned-goal { color: #b9a26a; font-weight: 400; }

.tycoon-bar { position: relative; height: 22px; }
.tycoon-bar-track, .tycoon-bar-fill, .tycoon-bar-frame {
  position: absolute; inset: 0; box-sizing: border-box; border-style: solid;
  border-color: transparent; border-width: 0 24px;
  border-image: url(../img/bar-green.png) 0 12 fill stretch; image-rendering: pixelated;
}
.tycoon-bar[data-colour="blue"] > * { border-image-source: url(../img/bar-blue.png); }
.tycoon-bar[data-colour="yellow"] > * { border-image-source: url(../img/bar-yellow.png); }
.tycoon-bar-track { filter: grayscale(1) brightness(.38); }
.tycoon-bar > .tycoon-bar-frame { border-image-source: url(../img/bar-frame.png); }
.tycoon-bar-text {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  overflow: hidden; color: #fff; font-size: .9rem; font-weight: 700;
  font-variant-numeric: tabular-nums; white-space: nowrap;
  text-shadow: 1px 1px 0 #000, -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000;
}
.tycoon-milestone { height: 6px; background: #2a1c0c40; }
.tycoon-milestone > div { height: 100%; background: #8a5a12; }

.tycoon-hint {
  position: absolute; z-index: 3; padding: 5px 12px 4px; border: 2px solid #2d2108;
  border-radius: 999px; background: #f3d37a; box-shadow: 0 2px 6px #0000008c; color: #1c1408;
  font-size: .875rem; font-weight: 700; line-height: 1.2; white-space: nowrap;
  pointer-events: none; animation: tycoon-hint-nudge 1s ease-in-out infinite;
}
.tycoon-hint-tile { top: -24px; left: -30px; --nudge: translateX(-50%); --nudge-to: translateX(-50%) scale(1.06); transform: var(--nudge); }
.tycoon-hint-tile[data-arrows="one"] { --nudge: translateX(-35%); --nudge-to: translateX(calc(-35% - 5px)); }
.tycoon-hint-tile[data-arrows="both"]:after { content: "  →"; }
.tycoon-hint-buy { top: calc(100% + 8px); left: 96px; --nudge: translateY(0); --nudge-to: translateY(-4px); transform: var(--nudge); }
.tycoon-hint-buy:before { content: "↑  "; }
@keyframes tycoon-hint-nudge { 0%, to { transform: var(--nudge); } 50% { transform: var(--nudge-to); } }
.tycoon-hint-anchor { flex: none; padding: 8px 0 0 96px; }
.tycoon-hint-tab { position: relative; width: fit-content; border-radius: 10px; white-space: normal; --nudge: translateY(0); --nudge-to: translateY(-4px); }
.tycoon-hint-tab:before { content: ""; position: absolute; top: -9px; left: 44px; border: 8px solid transparent; border-top: 0; border-bottom-color: #2d2108; }
.tycoon-hint-hire { display: flex; align-items: center; gap: 10px; }
.tycoon-hint-inline { position: static; --nudge: translateX(0); --nudge-to: translateX(4px); }
.tycoon-hint-inline:after { content: "  →"; }
.tycoon-tab[data-hint] { animation: tycoon-ready 1.2s ease-in-out infinite; }

.tycoon-row + .tycoon-row { border-top: 1px solid rgba(42, 28, 12, .25); }
.tycoon-group {
  display: flex; justify-content: space-between; gap: 8px; margin-top: 10px; padding: 4px 8px;
  border-top: 1px solid rgba(42, 28, 12, .4); border-bottom: 1px solid rgba(42, 28, 12, .4);
  background: #2a1c0c1f; font-weight: 700;
}
.tycoon-goal { display: flex; align-items: center; gap: 8px; margin-top: 3px; font-size: .875rem; }
.tycoon-goal > .tycoon-milestone { flex: 1; max-width: 220px; }
.tycoon-honour { margin-top: 4px; font-size: 1.25rem; font-weight: 700; color: #7a4b06; }
.tycoon-final { margin-top: 8px; border-top: 1px solid rgba(42, 28, 12, .25); border-bottom: 1px solid rgba(42, 28, 12, .25); }
.tycoon-row-new { background: #f3d37a66; }
.tycoon-new { padding: 1px 8px; border-radius: 999px; background: #b3261e; box-shadow: 0 0 0 1px #2d0906; color: #fff; font-size: .75rem; font-weight: 700; }
.tycoon-select {
  padding: 3px 6px 2px; background: #1c1a14; color: var(--tycoon-gold);
  border: 2px solid var(--tycoon-gold-dim); border-radius: 2px;
  font-family: inherit; font-size: .8rem; font-weight: 700; cursor: pointer;
}
.tycoon-medal {
  display: flex; flex: none; align-items: center; justify-content: center; width: 40px; height: 40px;
  border: 2px solid #5d5647; border-radius: 50%; background: #1c1a14; color: #5d5647;
  font-size: 1.25rem; line-height: 1;
}
.tycoon-medal[data-earned="true"] { border-color: var(--tycoon-gold-dim); box-shadow: inset 0 0 0 1px #d3a92f; color: var(--tycoon-gold); }
.tycoon-leader-gap {
  margin-top: 6px; padding: 4px 8px; border-top: 1px dashed rgba(42, 28, 12, .5);
  border-bottom: 1px dashed rgba(42, 28, 12, .5); font-size: .875rem; text-align: center;
}
.tycoon-leader {
  display: grid; grid-template-columns: 2rem minmax(0, 1fr) 3rem 4.5rem 8rem 11.5rem;
  align-items: baseline; gap: 0 12px; padding: 8px;
}
.tycoon-leader-head { font-size: .85rem; font-weight: 700; }
.tycoon-leader > [data-label] { text-align: right; }
.tycoon-leader-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tycoon-leader-rank { font-weight: 700; }
.tycoon-respawned { margin-left: 6px; padding: 0 5px; border-radius: 3px; background: #1f5f7a; color: #e6f4fa; font-size: .75rem; font-weight: 700; }
.tycoon-past-life { margin-left: 6px; padding: 0 5px; border: 1px solid rgba(42, 28, 12, .45); border-radius: 3px; color: var(--tycoon-ink-soft); font-size: .75rem; font-weight: 700; }

.tycoon-veil {
  position: absolute; inset: 0; z-index: 3; display: flex; align-items: center;
  justify-content: center; padding: 16px; background: #0009;
}
.tycoon-popup {
  display: flex; flex-direction: column; width: 100%; max-width: 460px; max-height: 100%;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .7)); text-align: center; animation: tycoon-rise .2s ease-out;
}
.tycoon-popup > .tycoon-inset { display: flex; flex-direction: column; min-height: 0; }
.tycoon-popup h2 { flex: none; font-size: 1.35rem; font-weight: 700; }
.tycoon-popup-body { min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #8a7a55 transparent; }
.tycoon-howto { margin-top: 8px; padding-left: 1.4em; list-style: decimal; text-align: left; }
.tycoon-howto li + li { margin-top: 4px; }
.tycoon-popup-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 12px; }
@keyframes tycoon-rise { 0% { opacity: 0; transform: translateY(10px); } }

.tycoon-quest-board { display: flex; flex-direction: column; gap: 8px; padding: 8px; }
.tycoon-quest-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; }
.tycoon-quest-ways { display: grid; grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); gap: 8px; }
.tycoon-quest-ways .tycoon-btn { display: flex; flex-direction: column; align-items: flex-start; height: auto; padding: 6px 10px; text-align: left; white-space: normal; }
.tycoon-quest-ways .tycoon-btn small { font-size: .8125rem; font-weight: 400; opacity: .8; }
.tycoon-quest-ways .tycoon-way { flex-direction: row; align-items: center; justify-content: flex-start; gap: 10px; padding: 8px 10px; }
.tycoon-way-art { position: relative; flex: none; border-radius: 2px; background: radial-gradient(circle, #ffe9a838, #ffe9a800 70%); }
.tycoon-way-art img { image-rendering: pixelated; }
.tycoon-way-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tycoon-way-tag { font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; opacity: .85; }
.tycoon-way-safe { background: linear-gradient(to bottom, #1d2a16, #0b1208 60%, #060a05); }
.tycoon-way-safe:hover:enabled { background: linear-gradient(to bottom, #2b3d20, #111a0c); }
.tycoon-way-bold { background: linear-gradient(to bottom, #3d1410, #1c0806 60%, #0e0403); border-color: #b8862a; }
.tycoon-way-bold:hover:enabled { background: linear-gradient(to bottom, #571d16, #260b08); }
.tycoon-way-slow { background: linear-gradient(to bottom, #13223a, #08101d 60%, #04080f); }
.tycoon-way-slow:hover:enabled { background: linear-gradient(to bottom, #1d3254, #0b1628); }
.tycoon-gamble { font-weight: 700; }
.tycoon-gamble-lost { color: #a3170c; }
.tycoon-gamble-won { color: #2c6a12; }

.tycoon-raffle {
  display: flex; flex: none; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 4px;
  padding: 6px 10px; border: 1px solid var(--tycoon-gold-dim);
  background: linear-gradient(to bottom, #3b2410, #22140a);
  box-shadow: inset 0 0 0 1px #f3d37a40; color: var(--tycoon-gold);
}
.tycoon-raffle-text { flex: 1 1 16rem; min-width: 0; }
.tycoon-raffle-line { color: #e8dcb8; }

.tycoon-changes { max-height: min(60vh, 520px); overflow-y: auto; padding-right: 6px; text-align: left; }
.tycoon-changes section + section { margin-top: 12px; padding-top: 10px; border-top: 1px solid rgba(42, 28, 12, .25); }
.tycoon-changes h3 { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-weight: 700; }
.tycoon-changes ul { margin-top: 4px; padding-left: 1.3em; list-style: disc; font-size: 1rem; }
.tycoon-changes li + li { margin-top: 4px; }

.tycoon-settings { display: grid; grid-template-columns: auto auto minmax(0, 1fr) 3rem; align-items: center; gap: 10px 12px; text-align: right; }
.tycoon-slider { width: 100%; accent-color: #8a5a12; cursor: pointer; }

/* 账号登录 / 注册表单 */
.tycoon-authform { display: flex; flex-direction: column; gap: 10px; }
.tycoon-input {
  width: 100%; padding: 10px 14px; font: inherit; font-size: 1rem;
  color: #3a2610; background: #fff3d0cc;
  border: 1px solid rgba(42, 28, 12, .5); border-radius: 6px;
}
.tycoon-input:focus { outline: none; border-color: #8a5a12; background: #fff8e6; }
.tycoon-days { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
.tycoon-days > li { display: flex; flex-direction: column; padding: 4px 0; border: 1px solid rgba(42, 28, 12, .45); font-size: .8125rem; line-height: 1.3; }
.tycoon-days > li[data-state="claimed"] { background: #2a1c0ccc; color: var(--tycoon-gold); }
.tycoon-days > li[data-state="today"] { border-color: #8f1d17; box-shadow: inset 0 0 0 2px #b3261e; background: #fff0c899; }

.t-row { display: flex; align-items: center; gap: 10px; padding: 8px; }
.t-row + .t-row { border-top: 1px solid rgba(42, 28, 12, .25); }
/* 原版 ye 的图标容器：固定盒子的 flex 居中 span */
.t-art-box { display: flex; flex: none; align-items: center; justify-content: center; }
.t-art-box img { image-rendering: pixelated; }
.t-row-main { flex: 1; min-width: 0; }
.t-row-title { font-weight: 700; font-size: 1.05rem; }
.t-row-detail { font-size: .9375rem; }
.t-row-action { flex: none; }
.t-row-dim { opacity: .55; }
.t-row-highlight { background: #f3d37a33; }
.t-intro { margin: 0; padding: 8px 8px 4px; font-size: 1rem; }
.t-bulk { padding: 8px; }
.t-pad { padding: 8px; }
.t-right { text-align: right; }
.t-bold { font-weight: 700; }
.t-mt2 { margin-top: 8px; }
.t-list { margin: 0; padding: 4px 8px 4px 1.9em; list-style: disc; }
.t-list li + li { margin-top: 4px; }
.t-dl { display: grid; grid-template-columns: 1fr auto; gap: 2px 16px; padding: 4px 8px; }
.t-dl dt { color: var(--tycoon-ink-soft); }
.t-dl dd { margin: 0; text-align: right; font-weight: 700; }
.t-section { margin: 8px 8px 0; font-size: 1.05rem; font-weight: 700; }
.t-quest-card { padding: 10px; border: 1px solid rgba(42, 28, 12, .35); }
.t-quest-card + .t-quest-card { margin-top: 8px; }
.t-quest-head { display: flex; align-items: center; gap: 10px; }
.t-respawn-head { display: flex; align-items: center; gap: 14px; padding: 8px 8px 0; }
.t-quest-title { font-size: 1.1rem; font-weight: 700; }
.t-quest-meta { font-size: .875rem; color: var(--tycoon-ink-soft); }
.t-h2 { margin: 12px 8px 0; font-size: 1.05rem; font-weight: 700; }
.t-scrolls { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; padding: 8px; }
.t-scrolls dl { display: grid; grid-template-columns: auto 1fr; gap: 2px 16px; flex: 1; font-variant-numeric: tabular-nums; }
.t-scrolls dt { color: var(--tycoon-ink-soft); }
.t-scrolls dd { margin: 0; font-weight: 700; }
.t-ach-group { margin-top: 12px; }
.t-ach-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 6px; padding: 6px 8px; }
.t-ach { display: grid; grid-template-columns: 2.2rem minmax(0, 1fr); gap: 8px; padding: 8px; border: 1px solid rgba(42, 28, 12, .3); }
.t-ach[data-earned="true"] { background: #f3d37a3d; border-color: var(--tycoon-gold-dim); }
.t-ach-icon { font-size: 1.5rem; text-align: center; }
.t-ach-name { font-weight: 700; }
.t-ach-desc { font-size: .875rem; color: var(--tycoon-ink-soft); }
.t-ach-meta { font-size: .8rem; color: var(--tycoon-ink-soft); }
.t-rarity-common { color: #6b6b6b; }
.t-rarity-rare { color: #1f5f9e; }
.t-rarity-epic { color: #7a4b06; }
.t-rarity-legendary { color: #a3170c; }
.t-toasts {
  position: absolute; right: 0; bottom: 40px; left: 0; z-index: 2;
  display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 0 16px; pointer-events: none;
}
.t-toast { max-width: 100%; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .7)); font-weight: 700; text-align: center; animation: tycoon-toast 4s ease-out forwards; }
.t-toast > .tycoon-inset { padding: 4px 14px; }
@keyframes tycoon-toast { 0% { opacity: 0; transform: translateY(12px); } 6%, 85% { opacity: 1; transform: none; } to { opacity: 0; } }
/* 金币雨：任务交接 / 功绩达成 / 新成就时的庆祝特效（对应原版 tycoon-rain） */
.t-rain { position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 61; overflow: hidden; pointer-events: none; }
.t-rain img { position: absolute; top: -40px; max-width: none; height: auto; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .6)); animation: tycoon-fall 2s linear both; }
@keyframes tycoon-fall { 0% { transform: translateY(0); } 85% { opacity: 1; } to { opacity: 0; transform: translateY(calc(100vh + 80px)); } }
.t-veil { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; padding: 16px; background: #0009; }
.t-worlds { display: flex; flex-direction: column; gap: 8px; }
.t-world {
  display: block; width: 100%; text-align: left; padding: 10px 12px;
  border: 2px solid var(--tycoon-gold-dim); border-radius: 3px;
  background: linear-gradient(to bottom, #1c1a14, #090a08 55%, #050605);
  color: var(--tycoon-gold); font: inherit; font-weight: 700; cursor: pointer;
}
.t-world[data-playing="true"] { border-color: #e2b53a; background: linear-gradient(to bottom, #7a5a10, #4b3606); color: #fff3c9; }
.t-world small { display: block; font-weight: 400; font-size: .8rem; opacity: .9; }
.t-hint-text { color: var(--tycoon-ink-soft); font-size: .9375rem; }
.t-tag { display: inline-block; padding: 0 6px; border-radius: 3px; font-size: .75rem; font-weight: 700; }

@media (max-width: 1000px) {
  .tycoon-grid { grid-auto-rows: minmax(136px, 1fr); }
  .tycoon-card-top { flex-direction: column; align-items: flex-start; gap: 0; height: 44px; }
  .tycoon-card-top > * { max-width: 100%; }
}
@media (max-width: 768px) {
  .tycoon-grid { grid-template-columns: minmax(0, 1fr); grid-auto-rows: 156px; }
  .tycoon-buyrow { grid-template-columns: minmax(0, 1fr); }
  .tycoon-card > .tycoon-inset { gap: 8px; }
  .tycoon-art { width: 84px; height: 96px; }
  .tycoon-hint-buy { top: calc(100% + 10px); left: 50%; --nudge: translateX(-50%); --nudge-to: translate(-50%, -4px); }
  .tycoon-hint-tile, .tycoon-hint-tile[data-arrows] { top: -30px; left: 50%; --nudge: translate(-50%, -50%); --nudge-to: translate(-50%, calc(-50% - 4px)); }
  .tycoon-hint-tile[data-arrows="both"] { --nudge-to: translate(-50%, -50%) scale(1.06); }
  .tycoon-hint-tile:before { content: "↑  "; }
  .tycoon-hint-tile[data-arrows="both"]:after { content: "  ↓"; }
}
@media (max-width: 640px) {
  .tycoon-screen { padding: 4px; }
  .tycoon-status { display: none; }
  .tycoon-pursebar { grid-template-columns: auto minmax(0, 1fr); height: 96px; }
  .tycoon-buymodes { grid-column: 1 / -1; }
  .tycoon-buymodes .tycoon-btn { flex: 1; }
  .tycoon-title { font-size: 1.15rem; }
  .tycoon-purse { font-size: 1.35rem; }
  .tycoon-tablet { border-width: 22px; }
  .tycoon-tablet > .tycoon-inset { margin: -6px -12px; }
  .tycoon-veil { padding: 8px; }
  .tycoon-popup.tycoon-scroll { border-width: 24px 22px 30px; }
  .tycoon-popup > .tycoon-inset { margin: -4px -6px -6px; }
  .tycoon-popup-body { font-size: .95rem; }
}
@media (prefers-reduced-motion: reduce) {
  .tycoon-art:enabled, .tycoon-card[data-idle], .tycoon-locked[data-ready] .tycoon-buy,
  .tycoon-tab[data-hint], .tycoon-hint, .tycoon-popup { animation: none; }
  .tycoon-card[data-idle] { outline-color: #ffc400b3; }
  .tycoon-hint { transform: var(--nudge); }
  .tycoon-toast { animation-name: tycoon-toast-plain; }
}
@keyframes tycoon-toast-plain { 85% { opacity: 1; } to { opacity: 0; } }

/* ---- 轻量工具类（等价于原版 Tailwind 原子类） ---- */
.flex { display: flex; }
.block { display: block; }
.inline-flex { display: inline-flex; }
.items-center { align-items: center; }
.items-baseline { align-items: baseline; }
.justify-between { justify-content: space-between; }
.flex-none { flex: none; }
.min-w-0 { min-width: 0; }
.min-h-full { min-height: 100%; }
.gap-1 { gap: 4px; }
.gap-2 { gap: 8px; }
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mb-1 { margin-bottom: 4px; }
.mb-2 { margin-bottom: 8px; }
.mr-1 { margin-right: 4px; }
.ml-1 { margin-left: 4px; }
.p-2 { padding: 8px; }
.pb-1 { padding-bottom: 4px; }
.pt-2 { padding-top: 8px; }
.text-base { font-size: 1rem; }
.text-sm { font-size: .875rem; }
.text-lg { font-size: 1.125rem; }
.font-bold { font-weight: 700; }
.underline { text-decoration: underline; }
.text-right { text-align: right; }
.text-center { text-align: center; }
.whitespace-nowrap { white-space: nowrap; }
.overflow-hidden { overflow: hidden; }
.relative { position: relative; }
.hidden { display: none; }

@media (min-width: 641px) {
  .sm\:hidden { display: none; }
}
@media (max-width: 640px) {
  .max-sm\:hidden { display: none; }
}

/* ===== 竞速榜（speed boards）新增样式 ===== */
.tycoon-rank-grid {
  display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 2px 16px;
  padding: 4px 8px 8px;
}
.tycoon-rank-grid select { justify-self: start; }
.tycoon-goal-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 8px 12px; padding: 8px;
}
.tycoon-goal-grid .tycoon-card { border: 1px dashed rgba(42, 28, 12, .4); }
.tycoon-speed-top { margin-top: 6px; }
.tycoon-speed-top-name { display: block; width: 100%; padding: 6px 8px 2px; border-bottom: 1px solid rgba(42, 28, 12, .25); font-weight: 700; text-align: left; }
.tycoon-leader-speed { display: grid; grid-template-columns: 2rem minmax(0, 1fr); gap: 0 12px; padding: 4px 8px 8px; align-items: baseline; }
.tycoon-life-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1fr) minmax(0, 1fr); gap: 2px 16px; padding: 4px 8px; }
.tycoon-life-grid > h3 { grid-column: 1 / -1; }
.tycoon-textarea {
  display: block; width: 100%; margin-top: 8px; padding: 6px 8px;
  border: 1px solid rgba(42, 28, 12, .6); background: #fffaebbf; color: var(--tycoon-ink);
  font: inherit; font-size: .95rem; resize: none;
}
@media (max-width: 640px) {
  .tycoon-goal-grid { grid-template-columns: 1fr; }
  .tycoon-life-grid { grid-template-columns: 1fr; }
}

/* ===== 任务抉择骰子角标（原版 .tycoon-way-dice） ===== */
.tycoon-way-art { position: relative; display: inline-flex; flex: none; }
.tycoon-way-dice {
  position: absolute; right: -8px; bottom: -6px; box-sizing: content-box;
  padding: 3px; border: 1px solid #b8862a; border-radius: 50%; background: #e9dcb6;
  font-size: .8rem; line-height: 1;
}
