@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Noto+Serif+SC:wght@400;500;600;700&display=swap');

/* release-marker: male-bond-v2-direct-card-claim-20260819 */

:root {
  --bg: #000;
  --bg-2: #000;
  --panel: #000;
  --surface: #000;
  --surface-2: #000;
  --line: rgba(225,235,229,.14);
  --line-strong: rgba(225,235,229,.29);
  --text: #f3efe5;
  --soft: rgba(243,239,229,.66);
  --faint: rgba(243,239,229,.38);
  --gold: #ebca7d;
  --gold-soft: rgba(235,202,125,.15);
  --mint: #63d7cc;
  --mint-soft: rgba(99,215,204,.14);
  --pink: #df6c9b;
  --pink-soft: rgba(223,108,155,.14);
  --danger: #f08b9a;
  --radius: 6px;
  --topbar: 72px;
  font-family: "Noto Serif SC", "Songti SC", serif;
  color: var(--text);
  background: var(--bg);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-width: 320px; min-height: 100%; background: var(--bg); }
body { overflow-x: hidden; }
button, a { font: inherit; color: inherit; touch-action: manipulation; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }
button, a, .lead-card, .switch-avatar, .feature-button, .gift-row, .reward-node {
  transition: color .18s ease, background-color .18s ease, border-color .18s ease, opacity .18s ease, transform .12s ease;
}
button:focus-visible, a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
button:active:not(:disabled), a:active { transform: scale(.98); }
[hidden] { display: none !important; }

.app {
  min-height: 100vh;
  background: #000;
}

.topbar {
  min-height: var(--topbar);
  padding: max(10px, env(safe-area-inset-top)) max(18px, env(safe-area-inset-right)) 10px max(18px, env(safe-area-inset-left));
  display: flex;
  align-items: center;
  gap: 18px;
  border-bottom:0;
  background: #000;
  backdrop-filter: none;
  position: sticky;
  top: 0;
  z-index: 30;
}

.icon-button, .text-control, .ghost-button, .primary-button, .secondary-button, .quantity-button {
  min-height: 44px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: rgba(255,255,255,.025);
}
.icon-button { width: 46px; display: grid; place-items: center; text-decoration: none; font-size: 30px; line-height: 1; }
.icon-button > .back-glyph { display: block; line-height: 1; transform: translateY(-3px); }
.icon-button:hover, .text-control:hover, .ghost-button:hover { border-color: var(--gold); color: var(--gold); }
.text-control { padding: 0 18px; margin-left: auto; }
.ghost-button { padding: 0 16px; color: var(--soft); }

.page-heading { min-width: 0; }
.page-heading small, .section-kicker, .world-heading small, .lead-identity span, .panel-eyebrow {
  font: 500 11px/1.2 "DM Mono", monospace;
  letter-spacing: .18em;
  color: var(--gold);
  text-transform: uppercase;
}
.page-heading h1 { margin: 4px 0 0; font-size: 25px; line-height: 1.1; font-weight: 600; }

/* overview */
.overview-topbar {
  gap: 0;
}
.overview-topbar .icon-button {
  width: 54px;
  border: 0;
  border-right: 0;
  border-radius: 0;
  background: transparent;
}
.overview-topbar .page-heading {
  display: grid;
  gap: 3px;
  min-width: 245px;
  padding: 0 22px;
}
.overview-topbar .page-heading small {
  font: 500 9px/1.1 "DM Mono", monospace;
  letter-spacing: .25em;
  color: var(--gold);
}
.overview-topbar .page-heading h1 {
  margin: 0;
  font-size: 22px;
  line-height: 1.1;
  font-weight: 500;
  letter-spacing: .12em;
}
.overview-count { margin-left: auto; display: flex; align-items: baseline; gap: 8px; color: var(--soft); }
.overview-count { flex:none; white-space:nowrap; }
.overview-count b { font: 500 28px/1 "DM Mono", monospace; color: var(--gold); }
.overview-count em { font-style: normal; color: var(--faint); }
.overview-intro {
  min-height: 154px;
  padding: 34px max(5vw, 32px);
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
  border-bottom: 1px solid var(--line);
  background: #000;
}
.overview-intro p { margin: 0 0 9px; font-size: clamp(24px, 3vw, 44px); line-height: 1.15; }
.overview-intro span { color: var(--soft); }
.collection-progress { width: min(380px, 33vw); height: 5px; background: var(--surface-2); overflow: hidden; }
.collection-progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--mint), var(--gold)); }
.world-stream { padding: 0 max(4vw, 24px) 80px; }
.world-section { padding: 34px 0 38px; border-bottom: 1px solid var(--line); }
.world-heading { margin-bottom: 20px; display: flex; justify-content: space-between; align-items: end; gap: 20px; }
.world-heading h2 { margin: 5px 0 0; font-size: 27px; font-weight: 500; }
.world-heading > span { color: var(--faint); font-size: 13px; }
.world-grid { display: grid; grid-template-columns: repeat(5, minmax(150px, 1fr)); gap: 12px; }
.lead-card {
  position: relative;
  min-height: 0;
  aspect-ratio: 3 / 4.35;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #000;
  color: var(--text);
  text-align: left;
  text-decoration: none;
  padding: 0;
}
.lead-card.is-met:hover { border-color: rgba(235,202,125,.7); transform: translateY(-2px); }
.lead-card img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; filter: saturate(.78) brightness(.78); transition: .25s ease; }
.lead-card:hover img { filter: saturate(.9) brightness(.88); transform: scale(1.015); }
.card-fallback { position: absolute; inset: 0; display: grid; place-items: center; background: #000; }
.card-fallback i { font-style: normal; font-size: 52px; color: rgba(243,239,229,.18); }
.card-shade { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 32%, rgba(5,7,9,.26) 53%, rgba(5,7,9,.96) 91%); }
.card-state { position: absolute; top: 13px; z-index: 2; font-size: 11px; letter-spacing: .08em; }
.card-state { right: 13px; padding: 5px 8px; border: 1px solid var(--line); background: #000; border-radius: 4px; color: var(--soft); }
.card-copy { position: absolute; left: 17px; right: 17px; bottom: 16px; z-index: 2; }
.card-copy strong { display: block; font-size: 30px; line-height: 1.15; font-weight: 500; }
.card-copy span { display: block; margin-top: 8px; color: var(--soft); }
.card-copy em { display: block; margin-top: 7px; font: normal 500 13px/1.4 "DM Mono", monospace; color: var(--mint); }
.lead-card.is-locked { opacity: .62; }
.lead-card.is-locked img { filter: grayscale(.85) brightness(.46); }
.lead-card.is-locked .card-copy strong { font-size: 24px; }
.lock-seal { position: absolute; inset: 0; z-index: 3; display: grid; place-items: center; background: rgba(4,6,8,.22); }
.lock-seal i { width: 44px; height: 44px; border: 1px solid rgba(243,239,229,.36); border-radius: 50%; position: relative; }
.lock-seal i::before { content: ""; position: absolute; width: 12px; height: 9px; border: 2px solid var(--soft); border-bottom: 0; border-radius: 8px 8px 0 0; left: 14px; top: 9px; }
.lock-seal i::after { content: ""; position: absolute; width: 16px; height: 13px; background: var(--soft); border-radius: 2px; left: 13px; top: 18px; }

/* detail composition */
.detail-view { height: 100dvh; min-height: 600px; display: grid; grid-template-columns: 78px 132px minmax(300px, 42vw) minmax(420px, 1fr); grid-template-rows: var(--topbar) minmax(0,1fr); overflow: hidden; }
.detail-topbar { position: relative; grid-column: 1 / -1; grid-row: 1; }
.detail-heading {
  min-width: 220px;
  padding: 0 22px;
  display: grid;
  align-content: center;
  gap: 3px;
  border-right: 1px solid var(--line);
  white-space: nowrap;
}

.detail-topbar {
  gap: 0;
}

.detail-topbar > .icon-button {
  width: 54px;
  border: 0;
  border-right: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}
.detail-heading small {
  display: block;
  font: 500 9px/1.1 "DM Mono", monospace;
  letter-spacing: .24em;
  color: var(--gold);
}
.detail-heading h1 {
  margin: 0;
  font-size: 23px;
  line-height: 1.1;
  font-weight: 500;
  letter-spacing: .12em;
}
.resource-hud { margin-left: auto; display: flex; gap: 9px; }
.resource-hud .currency-pill { flex-basis: 112px; min-width: 112px; height: 46px; grid-template-columns: 32px minmax(34px,1fr) 28px; background: #000; backdrop-filter: none; box-shadow: none; cursor: default; }
.resource-hud .currency-pill[data-action] { cursor: pointer; }
.resource-hud .currency-pill.is-static { grid-template-columns: 32px minmax(40px,1fr); }
.resource-hud .currency-pill img { width: 31px; height: 31px; }
.resource-hud .currency-pill__copy { height: 100%; padding: 0 3px; display: grid; place-items: center; }
.resource-hud .currency-pill__copy strong { font-size: 15px; font-weight: 400; line-height: 1; }
.resource-hud .currency-pill__add.is-static { color: var(--faint); }
.lead-switcher { grid-column: 1; grid-row: 2; padding: 14px 10px; border-right: 1px solid var(--line); background: #000; overflow-y: auto; scrollbar-width: none; }
.switch-avatar { width: 56px; height: 56px; margin: 0 auto 13px; display: grid; place-items: center; position: relative; border: 1px solid var(--line); border-radius: 50%; overflow: hidden; background: #000; color: var(--faint); }
.switch-avatar img { width: 100%; height: 100%; object-fit: cover; }
.switch-avatar.is-active { border: 2px solid #f4d47f; box-shadow: 0 0 0 2px #000, 0 0 0 4px rgba(244,212,127,.92), 0 0 18px rgba(244,212,127,.34); filter: brightness(1.12) saturate(1.08); }
.switch-avatar.is-locked { opacity: .46; }
.switch-avatar span { font-size: 18px; }
.portrait-stage { grid-column: 3; grid-row: 2; position: relative; overflow: hidden; border-right: 1px solid var(--line); background: #000; }
.stage-geometry { display: none; }
.lead-portrait { position: absolute; left: 0; right: auto; top: auto; bottom: -8%; width: 100%; height: 108%; object-fit: contain; object-position: center bottom; filter: saturate(.82) contrast(1.04) brightness(.93); -webkit-mask-image: linear-gradient(0deg,transparent 0,#000 8%,#000 100%); mask-image: linear-gradient(0deg,transparent 0,#000 8%,#000 100%); }
.portrait-fallback { position: absolute; inset: 0; display: grid; place-items: center; background: #000; }
.portrait-fallback::before { content: ""; width: 44%; height: 62%; border-radius: 48% 48% 18% 18%; background: linear-gradient(180deg, rgba(243,239,229,.09), rgba(243,239,229,.025)); box-shadow: 0 -60px 0 -15px rgba(243,239,229,.07); }
.portrait-fallback span { position: absolute; font-size: 64px; color: rgba(243,239,229,.13); }
.lead-identity { position: absolute; z-index: 4; left: 28px; right: 24px; bottom: 24px; text-shadow: 0 2px 18px #000; }
.lead-identity span { font-size: 13px; }
.lead-identity h2 { margin: 7px 0 13px; font-size: clamp(42px,5vw,72px); font-weight: 500; line-height: 1; }
.lead-identity p { margin: 0; color: var(--gold); font: 500 14px/1.25 "DM Mono", monospace; letter-spacing: .06em; }
.feature-nav { grid-column: 2; grid-row: 2; padding: 18px 8px; border-right: 0; background: transparent; display: flex; flex-direction: column; justify-content: center; gap: 2px; overflow-y: auto; }
.feature-button { text-decoration: none; min-height: 48px; padding: 7px 9px; border: 0; border-radius: var(--radius); background: transparent; color: var(--soft); text-align: left; display: grid; grid-template-columns: 20px minmax(0,1fr); align-items: center; gap: 7px; }
.feature-button:hover:not(.is-active) { background: rgba(255,255,255,.035); color: var(--text); }
.feature-icon { width: 20px; height: 20px; display: grid; place-items: center; border: 1px solid currentColor; border-radius: 50%; opacity: .8; }
.feature-icon svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.feature-copy { min-width: 0; }
.feature-button strong { display: block; overflow: hidden; font-size: 14px; font-weight: 500; line-height: 1.25; white-space: nowrap; text-overflow: ellipsis; }
.feature-button small { display: none; }
.feature-button.is-active { color: #243238; background: linear-gradient(90deg,rgba(247,244,235,.96),rgba(247,244,235,.72)); text-shadow: none; box-shadow: 0 4px 18px rgba(0,0,0,.16); }
.feature-button.is-locked { opacity: .55; }
.content-panel { grid-column: 4; grid-row: 2; min-width: 0; padding: clamp(22px, 3vw, 48px); overflow-y: auto; background: #000; }

/* panel components */
.panel-header { display: flex; align-items: start; justify-content: space-between; gap: 24px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.panel-header h2 { margin: 7px 0 5px; font-size: clamp(34px,3.2vw,56px); line-height: 1.05; font-weight: 500; }
.panel-header p { margin: 0; max-width: 700px; color: var(--soft); line-height: 1.7; }
.status-badge { padding: 8px 11px; border: 1px solid var(--line-strong); border-radius: 4px; color: var(--soft); white-space: nowrap; }
.status-badge.is-ready { border-color: rgba(99,215,204,.5); color: var(--mint); }
.status-badge.is-warning { border-color: rgba(223,108,155,.5); color: #f2a4c2; }
.context-label { align-self: flex-start; padding: 9px 0; color: var(--soft); font-size: 15px; white-space: nowrap; }
.level-overview { padding: 24px 0 18px; }
.level-row { display: flex; justify-content: space-between; align-items: end; gap: 20px; }
.level-number { font: 500 clamp(42px,5vw,74px)/1 "DM Mono", monospace; }
.level-number small { font-size: 18px; color: rgba(240,236,228,.54); }
.level-side { text-align: right; color: var(--soft); }
.level-side b { color: var(--text); font: 500 20px/1 "DM Mono", monospace; }
.progress { height: 7px; margin-top: 14px; background: rgba(255,255,255,.09); overflow: hidden; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg,var(--mint),var(--gold)); box-shadow: 0 0 16px rgba(99,215,204,.22); }
.progress-meta { margin-top: 9px; display: flex; justify-content: space-between; color: rgba(240,236,228,.54); font-size: 12px; }
.gate-panel { margin-top: 16px; padding: 16px 18px; border-left: 3px solid var(--pink); background: var(--pink-soft); display: flex; align-items: center; gap: 18px; }
.gate-panel div { flex: 1; }
.gate-panel strong { display: block; margin-bottom: 5px; }
.gate-panel p { margin: 0; color: var(--soft); font-size: 13px; }
.pending-value { color: #f4a7c4; white-space: nowrap; }
.action-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 12px; margin-top: 18px; }
.action-card, .summary-card, .condition-card, .visit-stage, .reward-card, .story-card, .life-card {
  border: 1px solid var(--line);
  background: var(--surface);
}
.action-card { min-height: 112px; padding: 17px; display: flex; align-items: center; gap: 14px; text-align: left; border-radius: var(--radius); }
.action-card:hover:not(:disabled) { border-color: var(--line-strong); background: var(--surface-2); }
.action-card:disabled { opacity: .45; }
.action-icon { width: 48px; height: 48px; display: grid; place-items: center; border: 1px solid rgba(235,202,125,.45); color: var(--gold); font-size: 20px; flex: 0 0 auto; }
.action-card strong { display: block; font-size: 18px; }
.action-card small { display: block; margin-top: 6px; color: var(--faint); line-height: 1.45; }
.action-card em { margin-left: auto; font-style: normal; color: var(--gold); }
.gift-action-row { margin-top: 20px; display: flex; justify-content: flex-end; }
.gift-action-button { width: min(100%, 250px); min-height: 50px; padding: 6px 10px; display: flex; align-items: center; gap: 10px; border: 1px solid var(--gold); border-radius: var(--radius); background: linear-gradient(135deg,#f0d68e,#dfba62); color: #18140d; text-align: left; box-shadow: 0 8px 24px rgba(0,0,0,.18); }
.gift-action-button:hover:not(:disabled) { background: linear-gradient(135deg,#f5dfa4,#e8c976); transform: translateY(-1px); }
.gift-action-button:focus-visible { outline: 2px solid var(--text); outline-offset: 3px; }
.gift-action-button:disabled { opacity: .38; filter: grayscale(.55); cursor: not-allowed; }
.gift-action-icon { width: 34px; height: 34px; flex: 0 0 34px; display: grid; place-items: center; border: 1px solid rgba(24,20,13,.4); }
.gift-action-icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.45; stroke-linecap: round; stroke-linejoin: round; }
.gift-action-copy { min-width: 0; flex: 1; }
.gift-action-button strong { display: block; font-size: 16px; }
.gift-action-button em { flex: 0 0 auto; font-size: 13px; font-style: normal; font-weight: 600; white-space: nowrap; }
.gift-action-button em b { margin-left: 6px; font-size: 16px; }
.next-reward { margin-top: 16px; padding: 16px 18px; border: 1px solid rgba(235,202,125,.28); display: flex; align-items: center; gap: 16px; }
.next-reward > span { font: 500 14px/1 "DM Mono", monospace; color: var(--gold); }
.next-reward div { flex: 1; }
.next-reward strong { display: block; }
.next-reward small { color: var(--soft); }
.primary-button, .secondary-button { min-width: 124px; padding: 0 18px; }
.primary-button { background: var(--gold); border-color: var(--gold); color: #18130b; font-weight: 600; }
.primary-button:hover:not(:disabled) { background: #f3d994; }
.primary-button:disabled { background: rgba(235,202,125,.2); border-color: rgba(235,202,125,.25); color: var(--faint); }
.secondary-button { color: var(--soft); }
.secondary-button:hover:not(:disabled) { border-color: var(--gold); color: var(--gold); background: rgba(235,202,125,.06); }
.text-button { min-height: 44px; border: 0; background: transparent; color: var(--gold); padding: 8px 0; }

/* visit */
.visit-wallet { display: flex; gap: 10px; flex-wrap: wrap; }
.visit-path { margin-top: 18px; display: grid; grid-template-columns: repeat(5,1fr); gap: 0; border-bottom: 1px solid var(--line); }
.path-node { min-width: 0; min-height: 74px; padding: 12px 10px 10px; border: 0; border-bottom: 3px solid transparent; background: transparent; color: var(--soft); position: relative; text-align: left; }
.path-node:hover { background: rgba(255,255,255,.035); color: var(--text); }
.path-node strong { display: block; font-size: 14px; }
.path-node small { display: block; margin-top: 6px; color: var(--faint); }
.path-node.is-done .node-mark { color: var(--mint); opacity: .76; }
.path-node.is-current .node-mark { color: var(--gold); }
.path-node.is-selected { border-bottom-color: var(--gold); color: var(--text); background: linear-gradient(180deg,transparent,rgba(235,202,125,.08)); }
.path-node.is-done.is-selected { border-bottom-color: var(--mint); }
.path-node .node-mark { display: block; margin-bottom: 8px; font: 500 10px/1 "DM Mono", monospace; letter-spacing: .12em; color: var(--faint); }
.visit-focus { margin-top: 18px; padding: 22px 0 0; border: 0; background: transparent; }
.visit-focus h3 { margin: 0 0 6px; font-size: 25px; }
.visit-focus > p { margin: 0; color: var(--soft); }
.visit-focus-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; }
.visit-focus-heading span { color: var(--mint); font-size: 11px; }
.visit-focus-heading p { margin: 0; max-width: 48%; color: var(--soft); text-align: right; }
.visit-progress-line, .visit-preview-meta { margin-top: 18px; display: flex; align-items: center; justify-content: space-between; gap: 18px; color: var(--soft); font-size: 13px; }
.visit-progress-line b { margin-left: 8px; color: var(--text); font: 500 16px/1 "DM Mono", monospace; }
.visit-focus.is-preview { padding-bottom: 8px; }
.visit-preview-meta { padding: 14px 0; }
.visit-actions { margin-top: 24px; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.visit-actions .primary-button { min-width: 190px; }
.visit-focus > .visit-actions { justify-content: flex-end; }
.visit-focus > .visit-actions .primary-button { width: min(100%,250px); min-width: 0; min-height: 50px; }
.visit-completion { display: grid; gap: 18px; }
.completion-hero { display: flex; align-items: center; justify-content: flex-start; gap: 24px; }
.completion-hero h3 { margin-top: 5px; }
.completion-hero p { margin: 0; color: var(--soft); }
.completion-stats { margin: 0; display: grid; grid-template-columns: repeat(3,1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.completion-stats > div { padding: 14px 16px; }
.completion-stats > div + div { border-left: 1px solid var(--line); }
.completion-stats dt { color: var(--faint); font-size: 11px; }
.completion-stats dd { margin: 5px 0 0; color: var(--text); font: 500 16px/1.2 "DM Mono", monospace; }
.completion-actions { padding: 15px 17px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-left: 3px solid var(--gold); background: linear-gradient(90deg,rgba(235,202,125,.08),transparent 70%); }
.completion-actions > div:first-child { min-width: 0; }
.completion-actions > div:first-child span { display: block; color: var(--gold); font-size: 11px; letter-spacing: .12em; }
.completion-actions > div:first-child small { display: block; margin-top: 5px; color: var(--soft); }
.completion-actions .visit-actions { margin-top: 0; flex-wrap: nowrap; }
.unclaimed-list { margin-top: 24px; padding-top: 18px; display: grid; gap: 9px; border-top: 1px solid var(--line); }
.unclaimed-row { min-height: 76px; padding: 12px 14px 12px 17px; display: flex; align-items: center; gap: 18px; border: 1px solid rgba(235,202,125,.55); border-left: 3px solid var(--gold); background: linear-gradient(90deg,rgba(235,202,125,.12),rgba(235,202,125,.025)); }
.unclaimed-copy { min-width: 0; flex: 1; }
.unclaimed-copy strong { display: block; font-size: 16px; }
.unclaimed-copy p { margin: 5px 0 0; color: var(--soft); font-size: 12px; }
.claim-button { min-width: 138px; min-height: 48px; padding: 0 16px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--gold); border-radius: var(--radius); background: var(--gold); color: #18130b; text-align: center; font-weight: 600; box-shadow: 0 8px 24px rgba(235,202,125,.16); }
.claim-button:hover { background: #f3d994; transform: translateY(-1px); }

/* life/story/rewards */
.condition-list, .story-list, .life-grid { margin-top: 20px; display: grid; gap: 10px; }
.unlock-panel { margin-top: 20px; padding: 18px 20px; border-left: 3px solid var(--pink); background: rgba(255,255,255,.025); }
.unlock-panel > header { display: flex; justify-content: space-between; align-items: end; gap: 18px; }
.unlock-panel > header span { display: block; color: var(--faint); font-size: 12px; }
.unlock-panel > header strong { display: block; margin-top: 4px; font-size: 19px; }
.unlock-panel > header p { margin: 0; color: var(--soft); font-size: 13px; }
.condition-card { padding: 13px 0; display: flex; align-items: center; gap: 13px; border: 0; border-top: 1px solid var(--line); background: transparent; }
.condition-card i { width: 28px; height: 28px; border: 1px solid var(--line-strong); border-radius: 50%; display: grid; place-items: center; font-size: 10px; font-style: normal; }
.condition-card.is-done i { color: var(--mint); border-color: var(--mint); }
.condition-card.is-pending i { color: #f2a4c2; border-color: rgba(223,108,155,.5); }
.condition-card div { flex: 1; }
.condition-card strong { display: block; }
.condition-card small { color: var(--faint); }
.condition-card > span { color: var(--faint); font-size: 12px; }
.condition-card.is-done > span { color: var(--mint); }
.life-grid { grid-template-columns: repeat(2,1fr); }
.life-card { min-height: 116px; padding: 17px; }
.life-card.is-locked { opacity: .43; }
.life-card span { color: var(--gold); font: 500 12px/1 "DM Mono", monospace; }
.life-card h3 { margin: 10px 0 5px; }
.life-card p { margin: 0; color: var(--soft); font-size: 13px; }
.story-card { min-height: 82px; padding: 16px 18px; display: flex; align-items: center; gap: 16px; position: relative; }
.story-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--line); }
.story-card.is-done::before { background: var(--mint); }
.story-card.is-ready { border-color: rgba(235,202,125,.5); background: var(--gold-soft); }
.story-card.is-ready::before { background: var(--gold); }
.story-card.is-locked { opacity: .48; }
.story-card:is(button) { width: 100%; border-radius: var(--radius); color: var(--text); text-align: left; }
.story-card:is(button):hover { border-color: var(--line-strong); background: var(--surface-2); }
.story-index { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid var(--line-strong); border-radius: 50%; color: var(--soft); font: 500 12px/1 "DM Mono", monospace; }
.story-card.is-done .story-index { color: var(--mint); border-color: rgba(99,215,204,.48); }
.story-card.is-ready .story-index { color: var(--gold); border-color: rgba(235,202,125,.58); }
.story-card div { flex: 1; }
.story-card strong { display: block; }
.story-card small { color: var(--faint); }
.story-state { color: var(--soft); }
.reward-toolbar { margin-top: 18px; display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.reward-toolbar p { margin: 0; color: var(--soft); }
.reward-progress { display: flex; align-items: center; gap: 7px; }
.reward-progress b { color: var(--text); font: 500 22px/1 "DM Mono", monospace; }
.reward-progress small { color: var(--faint); font: 400 12px/1 "DM Mono", monospace; }
.reward-grid { margin-top: 14px; display: grid; grid-template-columns: repeat(4,1fr); gap: 8px; }
.reward-card { min-height: 140px; padding: 13px; position: relative; }
.reward-card .reward-level { color: var(--gold); font: 500 12px/1 "DM Mono", monospace; }
.reward-card h3 { margin: 15px 0 6px; font-size: 16px; }
.reward-card p { margin: 0; color: var(--faint); font-size: 12px; line-height: 1.5; }
.reward-card button { position: absolute; left: 12px; right: 12px; bottom: 11px; min-height: 34px; border: 1px solid var(--line); border-radius: 4px; background: transparent; color: var(--soft); }
.reward-card.is-claimable { border-color: rgba(235,202,125,.58); background: var(--gold-soft); }
.reward-card.is-claimed { border-color: rgba(99,215,204,.3); }
.reward-card.is-claimed button { color: var(--mint); }
.reward-card.is-locked { opacity: .48; }
.reward-catalog { margin-top: 14px; border-top: 1px solid var(--line); }
.reward-pack { min-height: 104px; padding: 12px 0; display: grid; grid-template-columns: 140px minmax(0,1fr); gap: 14px; border-bottom: 1px solid var(--line); background: transparent; container: reward-pack / inline-size; }
.reward-pack.is-current { border-left: 3px solid var(--mint); background: linear-gradient(90deg,rgba(99,215,204,.08),transparent 58%); }
.reward-pack.is-complete { border-left: 3px solid rgba(255,255,255,.18); opacity: .68; }
.reward-pack.is-locked { opacity: .48; }
.reward-pack-heading { padding: 8px 14px; align-self: center; }
.reward-pack-heading small,.reward-pack-heading strong { display: block; }
.reward-pack-heading small { color: var(--faint); font-size: 11px; }
.reward-pack.is-current .reward-pack-heading small { color: var(--mint); }
.reward-pack.is-complete .reward-pack-heading small { color: var(--faint); }
.reward-pack-heading .phase-index { font-family: "DM Mono", monospace; letter-spacing: .18em; }
.reward-pack-heading strong { margin-top: 7px; font-size: 16px; font-weight: 500; }
.reward-pack-items { display: grid; grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: max(210px,calc((100% - 3px)/4)); gap: 0; margin-right: 0; overflow-x: auto; overscroll-behavior-inline: contain; scroll-snap-type: inline proximity; scrollbar-width: none; border: 1px solid var(--line); background: rgba(255,255,255,.01); }
.reward-pack-items::-webkit-scrollbar { display: none; }
.reward-node { min-width: 0; min-height: 88px; padding: 12px 16px; display: grid; grid-template-columns: minmax(0,1fr); grid-template-rows: auto auto 1fr; grid-template-areas: "level" "title" "detail"; align-items: center; border: 0; border-right: 1px solid var(--line); border-radius: 0; background: transparent; text-align: left; overflow: hidden; scroll-snap-align: start; }
.reward-node:last-child { border-right: 0; }
.reward-node > span { grid-area: level; align-self: end; color: var(--faint); font: 500 10px/1.2 "DM Mono", monospace; letter-spacing: .04em; }
.reward-node > strong { grid-area: title; margin-top: 5px; overflow: hidden; max-width: 100%; font-size: 14px; font-weight: 500; line-height: 1.25; white-space: nowrap; text-overflow: ellipsis; }
.reward-node > small { grid-area: detail; align-self: start; min-height: 0; margin-top: 5px; overflow: hidden; max-width: 100%; color: var(--faint); font-size: 10px; line-height: 1.35; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.reward-node.is-claimable { position: relative; z-index: 1; margin: -1px 0; border: 1px solid var(--gold); border-radius: 5px; background: linear-gradient(105deg,rgba(235,202,125,.2),rgba(235,202,125,.06)); box-shadow: inset 3px 0 0 var(--gold), 0 8px 22px rgba(235,202,125,.08); cursor: pointer; }
.reward-node.is-claimable:hover { border-color: #f6dc9a; background: linear-gradient(105deg,rgba(235,202,125,.27),rgba(235,202,125,.1)); transform: translateY(-1px); }
.reward-node.is-claimable:active { transform: translateY(0); background: linear-gradient(105deg,rgba(235,202,125,.32),rgba(235,202,125,.12)); }
.reward-node.is-claimable:focus-visible { outline: 2px solid #f6dc9a; outline-offset: -4px; }
.reward-node.is-claimable > span { color: var(--gold); }
.reward-node.is-claimed { position: relative; border-color: rgba(255,255,255,.1); background: rgba(255,255,255,.012); opacity: .58; }
.reward-node.is-claimed::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: 0; height: 1px; background: rgba(99,215,204,.42); }
.reward-node.is-claimed > span { color: var(--faint); font-family: "DM Mono", monospace; }

@container reward-pack (max-width: 1000px) {
  .reward-pack-items { grid-auto-columns: calc((100% - 1px)/2); }
}

/* modal */
.modal-layer { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: max(18px,env(safe-area-inset-top)) max(18px,env(safe-area-inset-right)) max(18px,env(safe-area-inset-bottom)) max(18px,env(safe-area-inset-left)); }
.modal-scrim { position: absolute; inset: 0; border: 0; background: rgba(0,0,0,.72); backdrop-filter: blur(7px); }
.modal { position: relative; width: min(720px,100%); max-height: min(82vh,760px); overflow: auto; border: 1px solid var(--line-strong); background: #000; box-shadow: 0 28px 80px rgba(0,0,0,.52); }
.modal-close { position: sticky; float: right; top: 10px; margin: 10px; z-index: 2; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: var(--radius); background: #000; font-size: 25px; }
.modal-body { padding: 30px; }
.modal-body h2 { margin: 5px 0 10px; font-size: 32px; font-weight: 500; }
.modal-intro { color: var(--soft); line-height: 1.7; }
.gift-list { margin-top: 20px; display: grid; gap: 9px; }
.gift-row { padding: 14px; display: grid; grid-template-columns: 52px 1fr auto; align-items: center; gap: 13px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--text); text-align: left; }
.gift-row:hover { border-color: var(--line-strong); background: var(--surface-2); }
.gift-row.is-selected { border-color: rgba(235,202,125,.62); background: var(--gold-soft); }
.gift-row.is-selected > span:last-child { color: var(--gold); }
.gift-symbol { width: 52px; height: 52px; display: grid; place-items: center; border: 1px solid rgba(235,202,125,.38); color: var(--gold); }
.gift-row h3, .gift-row p { margin: 0; }
.gift-row p { margin-top: 5px; color: var(--faint); font-size: 13px; }
.gift-control { display: flex; align-items: center; gap: 7px; }
.quantity-button { width: 44px; min-height: 44px; }
.quantity-button:hover:not(:disabled) { border-color: var(--gold); color: var(--gold); }
.quantity-button:disabled { opacity: .38; }
.quantity-value { min-width: 34px; text-align: center; font: 500 16px/1 "DM Mono", monospace; }
.gift-preview { margin-top: 15px; padding: 14px 16px; border-left: 3px solid var(--gold); background: var(--gold-soft); display: flex; justify-content: space-between; gap: 16px; }
.modal-actions { margin-top: 22px; display: flex; justify-content: flex-end; gap: 9px; }
.debug-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 9px; margin-top: 18px; }
.debug-grid button { min-height: 50px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); text-align: left; }
.toast {
  position: fixed; left: 50%; top: var(--toast-top, calc(var(--topbar) + 8px)); bottom: auto;
  z-index: 100; width: 340px; max-width: calc(100vw - 32px); min-height: 58px;
  padding: 10px 16px; display: grid; grid-template-columns: 24px minmax(0,1fr) 24px;
  align-items: center; gap: 12px; border: 1px solid var(--line-strong); border-radius: 6px;
  background: rgba(12,12,17,.96); box-shadow: 0 14px 44px rgba(0,0,0,.5);
  opacity: 0; pointer-events: none; transform: translate(-50%,-8px);
  transition: opacity .2s ease, transform .2s ease;
}
.toast svg { width: 24px; height: 24px; fill: none; stroke: var(--soft); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.toast strong { min-width: 0; text-align: center; overflow-wrap: anywhere; font: 600 13px/1.2 "Noto Serif SC", "Songti SC", serif; }
.toast.is-visible { opacity: 1; transform: translate(-50%,0); }
@media (prefers-reduced-motion: reduce) { .toast { transition: none; } }

@media (max-width: 1120px) {
  .world-grid { grid-template-columns: repeat(4,minmax(150px,1fr)); }
  .detail-view { grid-template-columns: 68px 112px minmax(250px,34vw) minmax(390px,1fr); }
  .resource-hud .currency-pill { flex-basis: 100px; min-width: 100px; }
  .reward-grid { grid-template-columns: repeat(3,1fr); }
}

@media (max-width: 900px) and (orientation: landscape) {
  :root { --topbar: 50px; }
  .detail-view { height: 100dvh; min-height: 0; grid-template-columns: 48px 96px 30vw minmax(0,1fr); grid-template-rows: var(--topbar) minmax(0,1fr); }
  .detail-topbar { grid-column: 1/-1; padding: max(3px,env(safe-area-inset-top)) max(8px,env(safe-area-inset-right)) 3px max(8px,env(safe-area-inset-left)); gap: 9px; min-height: 50px; position: relative; }
  .icon-button { width: 44px; min-height: 44px; height: 44px; }
  .detail-heading { min-width: 96px; display: block; }
  .detail-heading { padding: 0 9px; }
  .detail-heading small { display: block; overflow: hidden; max-width: 96px; font-size: 7px; white-space: nowrap; text-overflow: ellipsis; }
  .page-heading h1 { margin: 2px 0 0; font-size: 17px; }
  .resource-hud { gap: 5px; }
  .resource-hud .currency-pill { flex-basis: 82px; min-width: 82px; height: 44px; grid-template-columns: 27px minmax(26px,1fr) 20px; padding: 4px; }
  .resource-hud .currency-pill.is-static { grid-template-columns: 27px minmax(30px,1fr); }
  .resource-hud .currency-pill img { width: 27px; height: 27px; }
  .resource-hud .currency-pill__copy { padding: 0 4px; }
  .resource-hud .currency-pill__copy strong { font-size: 12px; font-weight: 400; }
  .resource-hud .currency-pill__add { height: 24px; font-size: 18px; }
  .text-control { min-height: 44px; padding: 0 10px; font-size: 12px; }
  .lead-switcher { grid-column: 1; grid-row: 2; padding: 6px 4px; }
  .switch-avatar { width: 44px; height: 44px; margin-bottom: 7px; }
  .portrait-stage { grid-column: 3; grid-row: 2; }
  .lead-identity { left: 14px; bottom: 13px; }
  .lead-identity span { font-size: 10px; }
  .lead-identity h2 { margin: 4px 0 9px; font-size: 32px; }
  .lead-identity p { font-size: 12px; }
  .feature-nav { grid-column: 2; grid-row: 2; padding: 4px; border-right: 0; border-bottom: 0; flex-direction: column; justify-content: center; gap: 2px; overflow-x: hidden; overflow-y: auto; }
  .feature-button { min-width: 0; width: 100%; min-height: 44px; padding: 5px 6px; grid-template-columns: 18px minmax(0,1fr); gap: 6px; text-align: left; white-space: nowrap; }
  .feature-button strong { font-size: 11px; line-height: 1.2; }
  .feature-icon { width: 18px; height: 18px; }
  .feature-icon svg { width: 10px; height: 10px; }
  .feature-button small { display: none; }
  .content-panel { grid-column: 4; grid-row: 2; padding: 14px 16px; }
  .panel-header { padding-bottom: 10px; gap: 10px; }
  .panel-header h2 { margin: 3px 0; font-size: 25px; }
  .panel-header p { font-size: 11px; line-height: 1.4; }
  .panel-eyebrow, .section-kicker { font-size: 8px; }
  .status-badge { padding: 5px 7px; font-size: 10px; }
  .level-overview { padding: 9px 0 5px; }
  .level-number { font-size: 34px; }
  .level-number small { font-size: 12px; }
  .level-side { font-size: 10px; }
  .level-side b { font-size: 14px; }
  .progress { margin-top: 7px; }
  .progress-meta { margin-top: 5px; font-size: 9px; }
  .gate-panel { margin-top: 7px; padding: 8px 10px; font-size: 10px; }
  .gate-panel p { font-size: 11px; }
  .action-grid { margin-top: 8px; gap: 7px; }
  .action-card { min-height: 70px; padding: 8px; gap: 8px; }
  .action-icon { width: 34px; height: 34px; font-size: 14px; }
  .action-card strong { font-size: 13px; }
  .action-card small { margin-top: 2px; font-size: 9px; }
  .gift-action-row { margin-top: 10px; }
  .gift-action-button { width: min(100%, 220px); min-height: 46px; padding: 5px 8px; gap: 7px; }
  .gift-action-icon { width: 32px; height: 32px; flex-basis: 32px; }
  .gift-action-icon svg { width: 18px; height: 18px; }
  .gift-action-button strong { font-size: 13px; }
  .gift-action-button em { font-size: 10px; }
  .next-reward { margin-top: 7px; padding: 8px 10px; font-size: 10px; }
  .next-reward small { font-size: 9px; }
  .primary-button, .secondary-button { min-height: 44px; min-width: 100px; padding: 0 12px; font-size: 11px; }
  .visit-path { margin-top: 9px; }
  .path-node { min-height: 54px; padding: 7px; }
  .path-node strong { font-size: 10px; }
  .path-node small { font-size: 8px; }
  .path-node .node-mark { margin-bottom: 5px; font-size: 7px; }
  .visit-focus { margin-top: 8px; padding: 10px; }
  .visit-focus h3 { font-size: 17px; }
  .visit-focus > p { font-size: 11px; }
  .visit-focus-heading p { font-size: 10px; }
  .visit-progress-line, .visit-preview-meta { margin-top: 8px; font-size: 9px; }
  .visit-progress-line b { font-size: 11px; }
  .visit-actions { margin-top: 14px; }
  .visit-focus > .visit-actions .primary-button { width: min(100%,220px); min-height: 46px; }
  .visit-completion { gap: 9px; }
  .completion-hero { gap: 10px; }
  .completion-hero p { font-size: 10px; }
  .completion-stats > div { padding: 8px; }
  .completion-stats dt { font-size: 8px; }
  .completion-stats dd { margin-top: 3px; font-size: 11px; }
  .completion-actions { padding: 8px 10px; gap: 9px; }
  .completion-actions > div:first-child small { font-size: 9px; }
  .completion-actions .visit-actions { gap: 6px; }
  .unclaimed-list { margin-top: 10px; padding-top: 9px; gap: 6px; }
  .unclaimed-row { min-height: 58px; padding: 7px 8px 7px 10px; gap: 10px; }
  .unclaimed-copy strong { font-size: 12px; }
  .unclaimed-copy p { margin-top: 3px; font-size: 9px; }
  .claim-button { min-width: 94px; min-height: 44px; padding: 0 10px; font-size: 11px; }
  .life-grid { margin-top: 9px; gap: 7px; }
  .life-card { min-height: 72px; padding: 9px; }
  .life-card h3 { margin: 5px 0 2px; font-size: 13px; }
  .life-card p { font-size: 11px; }
  .condition-list, .story-list { margin-top: 9px; gap: 6px; }
  .unlock-panel { margin-top: 8px; padding: 8px 10px; }
  .unlock-panel > header strong { font-size: 13px; }
  .unlock-panel > header p { font-size: 9px; }
  .condition-card, .story-card { padding: 8px 10px; font-size: 11px; }
  .condition-card { min-height: 44px; }
  .condition-card i { width: 24px; height: 24px; }
  .story-card { min-height: 50px; }
  .reward-toolbar { margin-top: 8px; }
  .reward-toolbar p { font-size: 11px; }
  .reward-progress b { font-size: 13px; }
  .reward-grid { margin-top: 7px; grid-template-columns: repeat(4,1fr); }
  .reward-catalog { margin-top: 7px; }
  .reward-pack { min-height: 94px; grid-template-columns: 82px minmax(0,1fr); gap: 6px; padding: 7px 0; }
  .reward-pack-heading { padding: 6px 7px; }
  .reward-pack-heading small { font-size: 10px; }
  .reward-pack-heading strong { margin-top: 5px; font-size: 12px; }
  .reward-pack-items { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: calc((100% - 1px)/2); gap: 0; margin-right: 0; overflow-x: auto; overscroll-behavior-inline: contain; scroll-snap-type: inline proximity; scroll-padding-inline: 1px; scrollbar-width: none; }
  .reward-node { min-height: 82px; padding: 9px 11px; scroll-snap-align: start; }
  .reward-node > span,.reward-node > small { font-size: 9px; }
  .reward-node > strong { margin-top: 4px; font-size: 12px; }
  .reward-node > small { min-height: 0; margin-top: 4px; line-height: 1.3; }
  .reward-card { min-height: 96px; padding: 7px; }
  .reward-card h3 { margin: 8px 0 3px; font-size: 11px; }
  .reward-card p { font-size: 10px; }
  .reward-card button { min-height: 44px; bottom: 6px; left: 6px; right: 6px; font-size: 9px; }
  .modal { max-height: calc(100dvh - 20px); }
  .modal-body { padding: 18px; }
  .modal-body h2 { font-size: 24px; }
  .modal-intro { font-size: 12px; }
  .gift-list { margin-top: 10px; gap: 6px; }
  .gift-row { padding: 8px; grid-template-columns: 38px 1fr auto; }
  .gift-symbol { width: 38px; height: 38px; }
  .gift-row h3 { font-size: 13px; }
  .gift-row p { font-size: 11px; }
  .world-grid { grid-template-columns: repeat(4,minmax(140px,1fr)); }
  .lead-card { min-height: 0; }
}

@media (max-width: 700px) and (orientation: landscape) {
  .detail-view { grid-template-columns: 44px 90px 29vw minmax(0,1fr); }
  .resource-control:nth-child(n+3) { display: none; }
  .portrait-stage { min-width: 0; }
  .lead-identity h2 { font-size: 27px; }
  .content-panel { padding: 11px 12px; }
  .panel-header p { display: none; }
  .action-grid { grid-template-columns: 1fr 1fr; }
  .action-card small { display: none; }
  .next-reward { display: none; }
  .reward-grid { grid-template-columns: repeat(3,1fr); }
}

@media (max-width: 720px) and (orientation: portrait) {
  .overview-intro { min-height: 128px; padding: 25px 18px; align-items: start; flex-direction: column; }
  .collection-progress { width: 100%; }
  .world-stream { padding: 0 14px 50px; }
  .world-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .lead-card { min-height: 280px; }
  .detail-view { display: block; }
  .detail-topbar { position: sticky; }
  .lead-switcher { display: flex; padding: 9px; border-right: 0; border-bottom: 1px solid var(--line); overflow-x: auto; }
  .switch-avatar { flex: 0 0 46px; height: 46px; margin: 0 7px 0 0; }
  .portrait-stage { height: 48vh; border-right: 0; border-bottom: 1px solid var(--line); }
  .feature-nav { padding: 8px; flex-direction: row; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .feature-button { min-width: 104px; }
  .content-panel { padding: 22px 16px 90px; }
  .reward-grid { grid-template-columns: repeat(2,1fr); }
  .reward-pack { grid-template-columns: 1fr; }
  .reward-pack-items { grid-template-columns: 1fr; margin: 0 0 10px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

/* interaction-redesign-marker: male-bond-v2-visit-action-divider-fix-20260825 */
.content-shell {
  grid-column: 4;
  grid-row: 2;
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: 58px minmax(0,1fr);
  background: #000;
}
.content-panel {
  grid-column: auto;
  grid-row: 2;
  min-height: 0;
  overscroll-behavior: contain;
}
.secondary-nav {
  min-width: 0;
  display: flex;
  align-items: stretch;
  gap: 2px;
  padding: 7px clamp(16px,3vw,44px) 0;
  border-bottom: 1px solid var(--line);
  background: #000;
  overflow-x: auto;
  scrollbar-width: none;
}
.secondary-nav::-webkit-scrollbar { display: none; }
.secondary-tab {
  position: relative;
  flex: 0 0 auto;
  min-width: 108px;
  min-height: 50px;
  padding: 0 16px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--soft);
  font-size: 14px;
}
.secondary-tab:hover { color: var(--text); }
.secondary-tab.is-active { color: var(--gold); border-bottom-color: var(--gold); }
.secondary-tab i {
  position: absolute;
  top: 4px;
  right: 4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--pink);
  color: #fff;
  font: normal 500 10px/1 "DM Mono",monospace;
}
.feature-nav { justify-content: center; gap: 8px; }
.feature-button { min-height: 58px; }
.feature-button.is-active { background: rgba(247,244,235,.92); }
.range-control { margin-top: 18px; padding: 16px; display: grid; gap: 12px; border: 1px solid var(--line); }
.range-control > span { display: flex; justify-content: space-between; align-items: center; }
.range-control output { color: var(--gold); font: 500 18px/1 "DM Mono",monospace; }
.range-control input {
  width: 100%;
  height: 44px;
  margin: 0;
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  cursor: pointer;
  touch-action: none;
}
.range-control input::-webkit-slider-runnable-track { height: 9px; border: 1px solid var(--line-strong); border-radius: 5px; background: linear-gradient(90deg,rgba(235,202,125,.88),rgba(255,255,255,.18)); }
.range-control input::-webkit-slider-thumb { width: 30px; height: 30px; margin-top: -11px; appearance: none; -webkit-appearance: none; border: 3px solid #0a0a0a; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 1px rgba(235,202,125,.7); }
.range-control input::-moz-range-track { height: 9px; border: 1px solid var(--line-strong); border-radius: 5px; background: rgba(255,255,255,.18); }
.range-control input::-moz-range-progress { height: 9px; border-radius: 5px; background: var(--gold); }
.range-control input::-moz-range-thumb { width: 26px; height: 26px; border: 3px solid #0a0a0a; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 1px rgba(235,202,125,.7); }
.reward-summary { margin-top: 18px; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.reward-summary span { padding: 11px 13px; border: 1px solid var(--line); color: var(--soft); }
.reward-summary b { margin-right: 9px; color: var(--gold); font-family: "DM Mono",monospace; }
.reward-node.is-claimed::after {
  content: "✓";
  position: absolute;
  left: auto;
  top: auto;
  right: 16px;
  bottom: 10px;
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(99,215,204,.62);
  border-radius: 50%;
  background: rgba(99,215,204,.06);
  color: var(--mint);
  font: normal 500 11px/1 sans-serif;
}
.reward-node.is-locked { cursor: pointer; }
.unclaimed-row { width: 100%; color: var(--text); text-align: left; }
.unclaimed-row > span { color: var(--gold); white-space: nowrap; }
.life-entry { margin-top: 20px; padding: 24px; border-left: 3px solid var(--line-strong); background: rgba(255,255,255,.02); }
.life-entry.is-ready { border-left-color: var(--mint); background: linear-gradient(90deg,rgba(99,215,204,.09),transparent 70%); }
.life-entry h3 { margin: 8px 0; font-size: 28px; font-weight: 500; }
.life-entry p { margin: 0; color: var(--soft); }
.stage-dots { margin-top: 22px; display: grid; grid-template-columns: repeat(5,1fr); gap: 8px; }
.stage-dots span { min-width: 0; padding: 12px 8px; display: grid; justify-items: center; gap: 7px; border-top: 1px solid var(--line); color: var(--faint); }
.stage-dots span.is-done { border-top-color: var(--mint); color: var(--mint); }
.stage-dots i { width: 26px; height: 26px; display: grid; place-items: center; border: 1px solid currentColor; border-radius: 50%; font: normal 500 10px/1 "DM Mono",monospace; }
.stage-dots b { overflow: hidden; max-width: 100%; font-size: 11px; font-weight: 400; white-space: nowrap; text-overflow: ellipsis; }
.completion-stats { grid-template-columns: repeat(2,1fr); }
.experience-settings {
  position: fixed;
  z-index: 70;
  box-sizing: border-box;
  width: max-content;
  min-width: 104px;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(235,202,125,.55);
  border-radius: var(--radius);
  background: rgba(0,0,0,.92);
  color: var(--gold);
  box-shadow: 0 8px 28px rgba(0,0,0,.5);
  white-space: nowrap;
  touch-action: none;
  user-select: none;
}
.experience-settings:hover { border-color: var(--gold); background: #11100c; }

@media (max-width: 900px) and (orientation: landscape) {
  .content-shell { grid-template-rows: 45px minmax(0,1fr); }
  .secondary-nav { padding: 1px 12px 0; }
  .secondary-tab { min-width: 88px; min-height: 44px; padding: 0 10px; font-size: 11px; }
  .content-panel { padding: 12px 14px; }
  .feature-nav { gap: 5px; }
  .feature-button { min-height: 50px; }
  .range-control { margin-top: 10px; padding: 10px; gap: 6px; }
  .range-control output { font-size: 14px; }
  .context-label { padding: 5px 0; font-size: 10px; }
  .life-entry { margin-top: 9px; padding: 12px; }
  .life-entry h3 { margin: 4px 0; font-size: 18px; }
  .life-entry p { font-size: 10px; }
  .stage-dots { margin-top: 10px; gap: 4px; }
  .stage-dots span { padding: 6px 3px; gap: 4px; }
  .stage-dots i { width: 22px; height: 22px; }
  .stage-dots b { font-size: 8px; }
  .experience-settings { min-width: 92px; min-height: 44px; padding: 0 10px; font-size: 11px; }
  .reward-summary { margin-top: 10px; gap: 5px; }
  .reward-summary span { padding: 7px 8px; font-size: 10px; }
}

@media (max-width: 720px) and (orientation: portrait) {
  .content-shell { display: block; }
  .secondary-nav { position: sticky; top: var(--topbar); z-index: 10; height: 54px; }
}

/* V1.101 formal alignment: approved 2026-08-31 */
:root { --topbar: 56px; --ui-muted: rgba(243,239,229,.62); }
body { font-size: 14px; line-height: 1.7; }
.topbar { padding: 4px 24px; gap: 12px; }
.topbar > .icon-button { flex: 0 0 44px; width: 44px; height: 44px; min-height: 44px; border: 0; border-radius: 6px; background: transparent; font-size: 28px; }
.topbar .page-heading { display: flex; flex-direction: row; align-items: center; gap: 10px; padding: 0; border: 0; }
.topbar .page-heading h1 { order: 0; margin: 0; font-size: 20px; line-height: 1; font-weight: 600; letter-spacing: .1em; }
.topbar .page-heading small { order: 1; color: rgba(255,255,255,.54); font: 500 10px/1 "DM Mono",monospace; letter-spacing: .18em; }
.overview-count { font-size: 11px; }
.overview-count b,.overview-count em { font: 600 14px/1.2 "DM Mono",monospace; }
.overview-intro { padding: 32px max(4vw,24px); gap: 24px; min-height: 0; }
.overview-intro p { margin: 0 0 12px; font-size: 20px; line-height: 1.2; font-weight: 600; }
.overview-intro span { font: 11px/1.5 "PingFang SC",sans-serif; }
.world-section { padding: 24px 0 32px; }
.world-heading { margin-bottom: 24px; gap: 24px; }
.world-heading small,.section-kicker,.panel-eyebrow { font: 500 9px/1.2 "DM Mono",monospace; }
.world-heading h2 { margin: 8px 0 0; font-size: 20px; line-height: 1.2; font-weight: 600; }
.world-heading > span { font: 11px/1.5 "PingFang SC",sans-serif; }
.card-copy strong,.lead-card.is-locked .card-copy strong { font-size: 14px; line-height: 1.4; font-weight: 600; }
.card-copy p { font: 11px/1.5 "PingFang SC",sans-serif; }
.card-copy em { font: 600 12px/1.2 "DM Mono",monospace; }
.card-state { top: 12px; right: 12px; min-height: 20px; padding: 0 8px; display: flex; align-items: center; font: 500 10px/1.2 "DM Mono",monospace; }
.detail-view { grid-template-columns: 88px 132px repeat(2,minmax(0,1fr)); }
.lead-switcher { padding: 12px 8px; }
.switch-avatar { box-sizing: content-box; width: 64px; height: 64px; border: 4px solid transparent; margin: 0 0 8px; background-clip: padding-box; overflow: visible; }
.switch-avatar img { border-radius: 50%; width: 64px; height: 64px; object-fit: cover; }
.switch-avatar::before { content: ""; position: absolute; inset: 0; border: 1px solid var(--line); border-radius: 50%; pointer-events: none; }
.switch-avatar.is-active { box-shadow: none; outline: none; }
.switch-avatar.is-active::before { border: 2px solid var(--gold); inset: -2px; }
.switch-avatar.is-active::after { display: none; }
.resource-hud { gap: 6px; }
.resource-hud .currency-pill { width: 132px; min-width: 132px; flex-basis: 132px; height: 48px; grid-template-columns: 34px minmax(0,1fr) 28px; background: rgba(8,9,13,.88); backdrop-filter: blur(12px); box-shadow: 0 4px 12px #0003; padding: 4px; }
.resource-hud .currency-pill img { width: 34px; height: 34px; }
.resource-hud .currency-pill__copy { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 4px; padding: 0 4px; }
.resource-hud .currency-pill__copy small { font: 500 9px/1 "Noto Serif SC","Songti SC",serif; color: rgba(255,255,255,.54); white-space: nowrap; }
.resource-hud .currency-pill__copy strong { font: 600 14px/1.2 "DM Mono",monospace; }
.resource-hud .currency-pill__add { font-size: 23px; }
.content-shell { grid-template-rows: 56px minmax(0,1fr); }
.secondary-nav { padding: 0 24px; gap: 8px; align-items: center; }
.secondary-tab { min-height: 44px; font-size: 13px; line-height: 1; padding: 0 16px; }
.secondary-tab i { top: 0; right: 0; height: 20px; min-width: 20px; background: #FF5F6D; }
.feature-button strong { font-size: 14px; line-height: 1.4; }
.content-panel { padding: 32px 24px; }
.panel-header { padding: 0; border: 0; gap: 24px; }
.panel-header h2 { margin: 8px 0 12px; font-size: 20px; line-height: 1.2; font-weight: 600; }
.panel-header p { margin: 0; font: 11px/1.5 "PingFang SC",sans-serif; color: var(--ui-muted); }
.status-badge { min-height: 20px; padding: 0 8px; display: flex; align-items: center; font: 500 10px/1.2 "DM Mono",monospace; }
.context-label { padding: 0; font: 11px/1.5 "PingFang SC",sans-serif; }
.level-overview { padding: 24px 0; }
.level-row { align-items: center; gap: 24px; }
.level-number { font: 600 32px/1.2 "DM Mono",monospace; }
.level-number strong { font-size: 30px; }
.level-number small { font-size: 14px; }
.level-side { font: 11px/1.5 "PingFang SC",sans-serif; }
.level-side b { font: 600 16px/1.2 "DM Mono",monospace; }
.progress { height: 8px; margin-top: 16px; }
.progress > i { background: var(--gold); }
.progress > i[style*="100%"] { background: var(--mint); }
.progress-meta { margin-top: 8px; font: 11px/1.5 "PingFang SC",sans-serif; }
.gate-panel { margin-top: 0; padding: 16px; gap: 16px; }
.gate-panel strong { font-size: 14px; line-height: 1.4; }
.gate-panel p { margin-top: 8px; font: 11px/1.5 "PingFang SC",sans-serif; }
.pending-value { font: 600 14px/1.2 "DM Mono",monospace; white-space: nowrap; }
.primary-button,.secondary-button,.claim-button { height: 44px; min-height: 44px; padding: 0 16px; font-size: 14px; line-height: 1; border-radius: 6px; font-weight: 600; }
.gift-action-row { margin-top: 24px; }
.gift-action-button { min-height: 48px; height: 48px; gap: 8px; padding: 0 12px; }
.gift-action-button strong,.gift-action-button em { font-size: 14px; }
.gift-action-icon { width: 28px; height: 28px; flex-basis: 28px; border: 0; }
.disabled-reason { color: var(--ui-muted); font: 11px/1.5 "PingFang SC",sans-serif; margin: 8px 0 0; text-align: right; }
#gift-disabled-reason { width: min(100%,250px); margin-left: auto; text-align: center; }
.visit-path { margin-top: 24px; overflow-x: auto; }
.path-node { min-height: 96px; min-width: 108px; padding: 12px 8px; text-align: center; }
.path-node .node-mark { font: 500 10px/1.2 "DM Mono",monospace; margin-bottom: 8px; }
.path-node strong { font-size: 13px; line-height: 1.4; }
.path-node small { margin-top: 4px; font: 11px/1.5 "PingFang SC",sans-serif; }
.stage-state { display: block; font: 10px/1.2 "DM Mono",monospace; margin-top: 8px; }
.visit-focus { margin-top: 24px; padding: 0; }
.visit-focus h3 { margin: 8px 0 0; font-size: 16px; line-height: 1.4; font-weight: 600; }
.visit-focus-heading { align-items: center; gap: 24px; }
.visit-focus-heading p { margin: 0; font: 11px/1.5 "PingFang SC",sans-serif; }
.visit-progress-line,.visit-preview-meta { margin-top: 24px; font: 12px/1.5 "PingFang SC",sans-serif; }
.visit-progress-line b { font: 600 12px/1.2 "DM Mono",monospace; }
.visit-actions { margin-top: 24px; justify-content: flex-end; }
.visit-focus > .visit-actions .primary-button { min-height: 44px; width: 250px; }
.story-list { margin-top: 24px; gap: 8px; }
.story-card { padding: 16px; gap: 16px; min-height: 80px; }
.story-card strong { font-size: 14px; line-height: 1.4; }
.story-card small { font: 11px/1.5 "PingFang SC",sans-serif; }
.story-state { font: 10px/1.2 "DM Mono",monospace; }
.reward-toolbar { margin-top: 24px; align-items: flex-start; }
.reward-toolbar > div { display: grid; justify-items: end; }
.reward-progress b { font-size: 16px; }
.reward-catalog { margin-top: 24px; border: 0; }
.reward-pack { grid-template-columns: 112px minmax(0,1fr); gap: 16px; padding: 16px 0; }
.reward-pack-heading { padding: 8px 12px; }
.reward-pack-heading strong { margin-top: 8px; font-size: 14px; }
.reward-pack-heading strong { white-space: nowrap; }
.reward-pack-items { grid-auto-columns: calc((100% - 1px)/2); scroll-snap-type: x mandatory; }
.reward-node { padding: 12px 16px 36px; min-height: 112px; position: relative; }
.reward-node > span { font: 500 10px/1.2 "DM Mono",monospace; }
.reward-node > strong { margin-top: 8px; font-size: 14px; line-height: 1.4; }
.reward-node > small { margin-top: 8px; min-height: 0; font: 11px/1.5 "PingFang SC",sans-serif; }
.reward-node.is-claimed::after { right: 12px; bottom: 8px; }
.life-entry { margin-top: 24px; padding: 16px; }
.life-entry h3 { font-size: 16px; line-height: 1.4; }
.life-entry p { font: 11px/1.5 "PingFang SC",sans-serif; }
.modal { width: min(640px,100%); max-height: calc(100dvh - 48px); overflow: hidden; background: #0c0c10; }
.modal-close { position: absolute; float: none; top: 16px; right: 16px; margin: 0; width: 44px; height: 44px; border: 0; background: transparent; font-size: 24px; }
.modal-body { padding: 0; display: flex; flex-direction: column; max-height: calc(100dvh - 48px); }
.modal-header { min-height: 76px; padding: 24px 64px; flex: none; display: grid; place-items: center; }
.modal-body .modal-header h2 { margin: 0; font: 600 18px/1.3 "Noto Serif SC","Songti SC",serif; text-align: center; }
.modal-body .modal-header h2:focus { outline: 0; }
.modal-scroll { padding: 0 32px; min-height: 0; overflow: auto; }
.modal-intro { margin: 0 0 24px; font: 14px/1.7 "Noto Serif SC","Songti SC",serif; }
.gift-list { margin: 0; gap: 8px; }
.gift-row { padding: 12px; gap: 12px; border-width: 2px; border-color: transparent; background: #15151c; }
.gift-row.is-selected { border-color: var(--gold); background: var(--gold-soft); }
.gift-row h3 { font-size: 14px; line-height: 1.4; }
.gift-row p { margin-top: 8px; font: 11px/1.5 "PingFang SC",sans-serif; }
.gift-row > span:last-child { display: none; }
.gift-row:disabled > span:last-child { display: block; font: 11px/1.5 "PingFang SC",sans-serif; }
.range-control { margin: 24px 0; padding: 16px; gap: 8px; border: 0; background: #15151c; }
.range-control b { font-size: 14px; line-height: 1.4; font-weight: 500; }
.range-control output { font: 600 14px/1.2 "DM Mono",monospace; }
.range-control input { height: 44px; }
.range-control input::-webkit-slider-runnable-track { height: 8px; border: 0; border-radius: 4px; background: linear-gradient(to right,var(--gold) 0 var(--range-fill,0%),#38383e var(--range-fill,0%) 100%); }
.range-control input::-webkit-slider-thumb { width: 26px; height: 26px; margin-top: -9px; border: 2px solid #15151c; box-shadow: 0 0 0 2px #ebca7d55; }
.range-control input::-moz-range-track { height: 8px; border: 0; background: #38383e; }
.range-control input::-moz-range-progress { height: 8px; background: var(--gold); }
.range-control input::-moz-range-thumb { box-sizing: border-box; width: 26px; height: 26px; border: 2px solid #15151c; }
.range-bounds { display: flex; justify-content: space-between; padding: 0 13px; font: 500 10px/1.2 "DM Mono",monospace; color: var(--ui-muted); }
.gift-preview { margin: 0; padding: 0; border: 0; background: transparent; gap: 16px; font-size: 13px; }
.gift-preview b { font: 600 14px/1.2 "DM Mono",monospace; }
.modal-footer { padding: 24px 32px 32px; flex: none; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.modal-footer .modal-actions { margin: 0; width: 100%; justify-content: center; }
.modal-footer .primary-button { min-width: 220px; }
.modal-footer .secondary-button[data-close-modal] { display: none; }
.modal-footer .disabled-reason { margin: 0; }

.modal.is-gift-modal { width: min(960px,100%); }
.modal.is-gift-modal .modal-scroll { padding-inline: 32px; }
.modal.is-gift-modal .modal-intro { margin-bottom: 16px; text-align: center; color: var(--ui-muted); }
.modal.is-gift-modal .gift-list { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; }
.modal.is-gift-modal .gift-row { min-width: 0; min-height: 112px; grid-template-columns: 52px minmax(0,1fr); align-content: center; }
.modal.is-gift-modal .gift-symbol { width: 52px; height: 52px; }
.modal.is-gift-modal .gift-row p { line-height: 1.6; }
.modal.is-gift-modal .range-control { margin: 20px 0 16px; }
.modal.is-gift-modal .range-bounds { padding-inline: 0; }
.modal.is-gift-modal .gift-preview { min-height: 44px; align-items: center; padding: 0 4px; }
.modal.is-gift-modal .modal-footer { padding-top: 18px; }
.modal.is-gift-modal .modal-footer .primary-button { min-width: 260px; }

@media (max-width: 1000px),(max-height: 560px) {
  .topbar { padding: 4px 14px; }
  .topbar .page-heading h1 { font-size: 17px; }
  .topbar .page-heading small { display: none; }
  .resource-hud .currency-pill { width: 104px; min-width: 104px; flex-basis: 104px; height: 44px; grid-template-columns: 24px minmax(0,1fr) 24px; }
  .resource-hud .currency-pill img { width: 24px; height: 24px; }
  .resource-hud .currency-pill__copy small { display: none; }
  .resource-hud .currency-pill__copy strong { font-size: 10px; }
  .resource-hud .currency-pill__add { font-size: 18px; }
  .detail-view { grid-template-columns: 64px 96px repeat(2,minmax(0,1fr)); }
  .lead-switcher { padding: 8px 4px; }
  .switch-avatar { width: 52px; height: 52px; border-width: 2px; }
  .switch-avatar img { width: 52px; height: 52px; }
  .content-panel { padding: 16px 14px; }
  .panel-header h2 { font-size: 17px; }
  .secondary-tab { font-size: 12px; padding: 0 12px; }
  .panel-header p { display: none; }
  .feature-button strong { font-size: 13px; }
  .primary-button,.secondary-button,.claim-button { font-size: 13px; }
  .reward-pack { grid-template-columns: 80px minmax(0,1fr); gap: 8px; }
  .reward-pack-heading strong { font-size: 12px; }
  .reward-pack-items { grid-auto-columns: 100%; }
  .modal,.modal-body { max-height: calc(100dvh - 24px); }
  .modal-header { min-height: 60px; padding: 16px 64px; }
  .modal-close { top: 8px; right: 12px; }
  .modal-body .modal-header h2 { font-size: 16px; }
  .modal-scroll { padding: 0 16px; }
  .modal-footer { padding: 16px; }
  .modal-intro { font-size: 13px; }
}

/* V1.102 optical alignment: approved 2026-09-01 */
.detail-topbar > .icon-button {
  padding: 0 0 4px;
}
.detail-topbar .page-heading {
  height: 44px;
  align-items: center;
}
.switch-avatar {
  box-sizing: border-box;
  width: 72px;
  height: 72px;
  aspect-ratio: 1;
  padding: 2px;
  border: 2px solid transparent;
  border-radius: 50%;
  margin: 0 auto 8px;
  overflow: hidden;
}
.switch-avatar::before {
  display: none;
}
.switch-avatar.is-active {
  border-color: var(--gold);
}
.switch-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
}
.feature-button {
  width: fit-content;
  max-width: 100%;
  align-self: flex-start;
  grid-template-columns: 20px auto;
}
.secondary-nav {
  align-items: stretch;
}
.secondary-tab {
  align-self: stretch;
  min-height: 0;
}

@media (max-width: 1000px),(max-height: 560px) {
  .switch-avatar {
    width: 56px;
    height: 56px;
    padding: 0;
  }
  .feature-button {
    grid-template-columns: 18px auto;
  }
}

/* V1.103 lead identity visual-left alignment: approved 2026-09-01 */
.lead-identity {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}
.lead-identity h2 {
  margin-left: -.08em;
}

/* V1.104 confirmed information reduction: 2026-09-01 */
.overview-view.is-simplified .world-stream {
  padding-top: 8px;
}

.overview-view.is-simplified .world-heading > span {
  color: var(--ui-muted);
  font: 500 11px/1.2 "DM Mono", monospace;
}

.overview-view.is-simplified .lead-card.is-met .card-copy,
.overview-view.is-simplified .lead-card.is-locked .card-copy {
  padding-top: 20px;
}

.content-panel .level-overview.is-simplified {
  padding-top: 8px;
}

.level-overview.is-simplified .level-row {
  align-items: flex-end;
}

.level-overview.is-simplified .summary-label {
  display: block;
  margin-bottom: 8px;
  color: var(--ui-muted);
  font: 11px/1.5 "PingFang SC", sans-serif;
}

.level-overview.is-simplified .level-number strong {
  font: inherit;
}

.level-overview.is-simplified .level-side {
  display: block;
}

.level-overview.is-simplified .level-side strong {
  color: var(--text);
  font: 600 24px/1.2 "DM Mono", monospace;
}

.level-overview.is-simplified .level-side small {
  color: var(--ui-muted);
  font: 500 14px/1.2 "DM Mono", monospace;
}

.level-overview.is-simplified .progress-meta {
  justify-content: flex-start;
}

.content-panel .gate-panel {
  min-height: 64px;
  padding: 12px 16px;
}

.content-panel .gate-panel > div {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.content-panel .gate-panel strong {
  margin: 0;
}

.content-panel .gate-panel > div > span {
  color: #f2a4c2;
  font: 500 11px/1.5 "PingFang SC", sans-serif;
}

.content-panel .gate-panel .secondary-button {
  min-width: 88px;
}

.content-panel .gift-action-button {
  width: 180px;
  justify-content: center;
}

.content-panel .gift-action-copy {
  flex: 0 0 auto;
}

.story-list.is-simplified,
.reward-toolbar.is-simplified,
.simple-page-summary,
.life-entry.is-simplified {
  margin-top: 0;
}

.reward-toolbar.is-simplified {
  min-height: 48px;
  align-items: center;
}

.reward-toolbar.is-simplified .reward-progress {
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.reward-toolbar.is-simplified .summary-label {
  margin-right: 8px;
  color: var(--ui-muted);
  font: 11px/1.5 "PingFang SC", sans-serif;
}

.simple-page-summary {
  min-height: 56px;
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.simple-page-summary > span,
.simple-page-summary > small {
  color: var(--ui-muted);
  font: 11px/1.5 "PingFang SC", sans-serif;
}

.simple-page-summary > strong {
  color: var(--text);
  font: 600 16px/1.2 "DM Mono", monospace;
}

.simple-page-summary > small {
  justify-self: end;
}

.visit-path.is-simplified {
  margin-top: 0;
}

.visit-path.is-simplified .path-node {
  min-height: 76px;
}

.life-entry.is-simplified {
  position: relative;
}

.life-entry.is-simplified .life-status {
  position: absolute;
  top: 16px;
  right: 16px;
  color: var(--mint);
  font: 500 10px/1.2 "DM Mono", monospace;
}

.life-entry.is-simplified.is-locked .life-status {
  color: var(--gold);
}

@media (max-width: 1000px), (max-height: 560px) {
  .content-panel .level-overview.is-simplified {
    padding-top: 0;
  }

  .level-overview.is-simplified .summary-label {
    margin-bottom: 4px;
    font-size: 10px;
  }

  .level-overview.is-simplified .level-side strong {
    font-size: 16px;
  }

  .content-panel .gate-panel {
    min-height: 52px;
    padding: 8px 12px;
  }

  .simple-page-summary {
    min-height: 44px;
  }

  .simple-page-summary > small {
    display: none;
  }
}
/* Mobile-landscape adaptation: 2026-09-01 */
.orientation-guard { display: none; }

@media (orientation: landscape) and (max-width: 1000px),
       (orientation: landscape) and (max-height: 560px) {
  html,
  body {
    width: 100%;
    height: var(--app-height, 100dvh);
    min-height: 0;
    overflow: hidden;
    overscroll-behavior: none;
  }

  .app,
  .overview-view,
  .detail-view {
    width: 100%;
    height: var(--app-height, 100dvh);
    min-height: 0;
    overflow: hidden;
  }

  .overview-view {
    display: grid;
    grid-template-rows: 50px minmax(0, 1fr);
  }

  .topbar,
  .overview-topbar,
  .detail-topbar {
    min-height: 50px;
    height: 50px;
    padding-top: max(3px, env(safe-area-inset-top));
    padding-right: max(14px, calc(env(safe-area-inset-right) + 8px));
    padding-bottom: 3px;
    padding-left: max(14px, calc(env(safe-area-inset-left) + 8px));
    gap: 8px;
  }

  .topbar > .icon-button,
  .overview-topbar .icon-button {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    min-height: 44px;
    border-right: 0;
  }

  .overview-topbar .page-heading {
    min-width: 0;
    padding: 0;
  }

  .overview-count {
    gap: 6px;
    white-space: nowrap;
  }

  .overview-count b,
  .overview-count em {
    font-size: 12px;
  }

  .overview-count em {
    color: rgba(255, 255, 255, .52);
  }

  .world-stream {
    min-height: 0;
    padding: 0 max(14px, calc(env(safe-area-inset-right) + 10px)) max(24px, calc(env(safe-area-inset-bottom) + 16px)) max(14px, calc(env(safe-area-inset-left) + 10px));
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }

  .overview-view.is-simplified .world-stream {
    padding-top: 0;
  }

  .world-section {
    padding: 16px 0 24px;
  }

  .world-heading {
    min-height: 44px;
    margin-bottom: 12px;
    align-items: center;
  }

  .world-heading small {
    font-size: 8.5px;
  }

  .world-heading h2 {
    margin-top: 4px;
    font-size: 17px;
  }

  .world-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
  }

  .lead-card {
    min-width: 0;
    aspect-ratio: 4 / 5;
  }

  .card-copy {
    left: 12px;
    right: 12px;
    bottom: 10px;
  }

  .card-copy span {
    margin-top: 4px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .card-copy em {
    margin-top: 4px;
  }

  .lock-seal i {
    width: 44px;
    height: 44px;
  }

  .detail-view {
    grid-template-columns: 58px 86px repeat(2,minmax(0,1fr));
    grid-template-rows: 50px minmax(0, 1fr);
  }

  .detail-topbar {
    grid-column: 1 / -1;
  }

  .detail-heading {
    flex: 0 1 auto;
    min-width: 68px;
    height: 44px;
    padding: 0;
    border-right: 0;
  }

  .detail-heading h1 {
    white-space: nowrap;
  }

  .resource-hud {
    margin-left: auto;
    gap: 4px;
  }

  .resource-hud .currency-pill {
    width: 104px;
    min-width: 104px;
    flex-basis: 104px;
  }

  .lead-switcher {
    grid-column: 1;
    grid-row: 2;
    padding: 8px 2px max(12px, calc(env(safe-area-inset-bottom) + 8px));
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .switch-avatar {
    width: 52px;
    height: 52px;
    min-width: 52px;
    min-height: 52px;
    margin: 0 auto 8px;
  }

  .feature-nav {
    grid-column: 2;
    grid-row: 2;
    width: 86px;
    padding: 8px 4px max(12px, calc(env(safe-area-inset-bottom) + 8px));
    gap: 8px;
    justify-content: center;
    overflow: hidden auto;
    overscroll-behavior: contain;
  }

  .feature-button {
    width: 78px;
    max-width: 78px;
    min-height: 48px;
    padding: 6px 8px;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 6px;
  }

  .feature-button strong {
    font-size: 12px;
  }

  .portrait-stage {
    grid-column: 3;
    grid-row: 2;
    min-width: 0;
  }

  .lead-portrait {
    left: 50%;
    width: 122%;
    max-width: none;
    transform: translateX(-50%);
    object-position: 52% bottom;
  }

  .lead-identity {
    left: 12px;
    right: 8px;
    bottom: max(12px, calc(env(safe-area-inset-bottom) + 8px));
  }

  .lead-identity h2 {
    margin: 4px 0 8px;
    font-size: 27px;
  }

  .lead-identity p {
    font-size: 11px;
  }

  .content-shell {
    grid-column: 4;
    grid-row: 2;
    grid-template-rows: 44px minmax(0, 1fr);
    min-width: 0;
    min-height: 0;
    overflow: hidden;
  }

  .secondary-nav {
    min-height: 44px;
    height: 44px;
    padding: 0 12px;
    gap: 8px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-padding-inline: 12px;
  }

  .secondary-tab {
    min-width: 88px;
    min-height: 44px;
    height: 44px;
    padding: 0 10px;
    font-size: 12px;
  }

  .content-panel {
    grid-row: 2;
    min-width: 0;
    min-height: 0;
    padding: 12px max(14px, calc(env(safe-area-inset-right) + 10px)) max(20px, calc(env(safe-area-inset-bottom) + 12px)) 14px;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }

  .level-overview.is-simplified .level-row {
    gap: 16px;
  }

  .level-overview.is-simplified .level-number strong {
    font-size: 24px;
  }

  .level-overview.is-simplified .progress-meta,
  .visit-progress-line,
  .visit-preview-meta {
    gap: 12px;
    flex-wrap: wrap;
  }

  .content-panel .gate-panel {
    min-height: 56px;
    gap: 12px;
  }

  .content-panel .gate-panel > div {
    min-width: 0;
    flex-wrap: wrap;
    gap: 4px 10px;
  }

  .story-card {
    min-height: 64px;
    padding: 10px 12px;
    gap: 10px;
  }

  .story-card > div {
    min-width: 0;
    flex: 1;
  }

  .story-card strong,
  .story-card small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .story-card strong {
    white-space: nowrap;
  }

  .story-state {
    white-space: nowrap;
  }

  .reward-toolbar.is-simplified {
    min-height: 56px;
    gap: 12px;
  }

  .reward-catalog {
    margin-top: 12px;
  }

  .reward-pack {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 8px;
    padding: 10px 0;
  }

  .reward-pack-items {
    grid-auto-columns: minmax(180px, 100%);
  }

  .reward-node {
    min-height: 96px;
    padding: 10px 12px 32px;
  }

  .simple-page-summary {
    min-height: 44px;
  }

  .visit-path.is-simplified {
    scroll-padding-inline: 1px;
  }

  .visit-path.is-simplified .path-node {
    min-width: 92px;
    min-height: 72px;
  }

  .visit-focus-heading {
    gap: 16px;
  }

  .visit-focus-heading p {
    max-width: 52%;
  }

  .modal-layer {
    padding-top: max(8px, env(safe-area-inset-top));
    padding-right: max(12px, calc(env(safe-area-inset-right) + 8px));
    padding-bottom: max(8px, env(safe-area-inset-bottom));
    padding-left: max(12px, calc(env(safe-area-inset-left) + 8px));
  }

  .modal,
  .modal-body {
    max-height: calc(var(--app-height, 100dvh) - max(16px, env(safe-area-inset-top) + env(safe-area-inset-bottom)));
  }

  .modal {
    width: min(680px, 100%);
  }

  .modal.is-gift-modal {
    width: min(760px,100%);
  }

  .modal-header {
    min-height: 52px;
    padding: 12px 64px;
  }

  .modal-close {
    top: 4px;
    right: 8px;
  }

  .modal-scroll {
    padding: 4px 20px 0;
    scrollbar-gutter: stable;
  }

  .modal-intro {
    margin-bottom: 16px;
  }

  .modal-footer {
    padding: 16px 20px max(16px, calc(env(safe-area-inset-bottom) + 8px));
  }

  .gift-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .gift-row {
    min-width: 0;
    grid-template-columns: 38px minmax(0, 1fr);
  }

  .modal.is-gift-modal .modal-scroll {
    padding-inline: 20px;
  }

  .modal.is-gift-modal .gift-list {
    gap: 8px;
  }

  .modal.is-gift-modal .gift-row {
    min-height: 92px;
    grid-template-columns: 38px minmax(0,1fr);
    padding: 10px;
  }

  .modal.is-gift-modal .gift-symbol {
    width: 38px;
    height: 38px;
  }

  .modal.is-gift-modal .gift-row p {
    white-space: normal;
  }

  .modal.is-gift-modal .range-control {
    margin: 12px 0 8px;
  }

  .modal.is-gift-modal .modal-footer {
    padding-top: 12px;
  }

  .gift-row p {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .range-control {
    margin: 16px 0;
    padding: 12px 16px;
  }

  .debug-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 8px;
  }

  .debug-grid button {
    min-height: 52px;
  }

  .experience-settings {
    position: static;
    flex: 0 0 auto;
    width: auto;
    min-width: 88px;
    min-height: 44px;
    height: 44px;
    margin: 0;
    padding: 0 12px;
    box-shadow: none;
    touch-action: manipulation;
  }

  .toast {
    max-width: calc(100vw - max(32px, env(safe-area-inset-left) + env(safe-area-inset-right) + 24px));
  }
}

@media (orientation: landscape) and (max-width: 780px) {
  .detail-view {
    grid-template-columns: 58px 82px repeat(2,minmax(0,1fr));
  }

  .feature-nav {
    width: 82px;
  }

  .feature-button {
    width: 74px;
    max-width: 74px;
  }

  .resource-hud .currency-pill {
    width: 92px;
    min-width: 92px;
    flex-basis: 92px;
  }

  .experience-settings {
    min-width: 80px;
    padding: 0 10px;
    font-size: 11px;
  }

  .portrait-stage .lead-portrait {
    width: 132%;
  }

  .reward-pack {
    grid-template-columns: 68px minmax(0, 1fr);
  }
}

@media (orientation: portrait) {
  body {
    height: var(--app-height, 100dvh);
    overflow: hidden;
  }

  .orientation-guard {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: grid;
    place-content: center;
    justify-items: center;
    gap: 12px;
    padding: max(24px, env(safe-area-inset-top)) max(24px, env(safe-area-inset-right)) max(24px, env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left));
    background: #000;
    color: var(--text);
    text-align: center;
  }

  .orientation-guard > span {
    color: var(--gold);
    font: 500 32px/1 "DM Mono", monospace;
  }

  .orientation-guard > strong {
    font-size: 17px;
    line-height: 1.4;
    letter-spacing: .08em;
  }
}

/* Detail density and overflow polish: 2026-09-02 */
.content-shell { position: relative; }

/* 共享页头由宿主网格定义高度，内部层不得溢出并遮挡下方标签。 */
.overview-topbar .page-header__inner,
.detail-topbar .page-header__inner {
  height: 100%;
  min-height: 0;
  padding: 0;
}

.detail-topbar { pointer-events: none; }
.detail-topbar .page-header__back,
.detail-topbar .page-header__lobby,
.detail-topbar .resource-control { pointer-events: auto; }
.content-scroll-cue {
  position: absolute;
  z-index: 8;
  left: 50%;
  bottom: max(8px,calc(env(safe-area-inset-bottom) + 4px));
  width: 44px;
  height: 44px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid rgba(235,202,125,.5);
  border-radius: 50%;
  background: rgba(0,0,0,.88);
  color: var(--gold);
  box-shadow: 0 8px 24px rgba(0,0,0,.46);
  transform: translateX(-50%);
}
.content-scroll-cue:hover { border-color: var(--gold); background: #15130d; }
.content-scroll-cue:active:not(:disabled) { transform: translateX(-50%) translateY(1px); }
.content-scroll-cue svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.gift-action-wrap { width: min(100%,250px); display: grid; justify-items: stretch; }
.gift-action-wrap .gift-action-button { width: 100%; }
#gift-disabled-reason { width: 100%; margin: 8px 0 0; text-align: center; }

.stage-dots b {
  color: var(--ui-muted);
  font-size: 11px;
  overflow: visible;
  white-space: normal;
  text-overflow: clip;
  text-align: center;
  line-height: 1.35;
}

.reward-list { margin-top: 24px; display: grid; border-top: 1px solid var(--line); }
.reward-row {
  width: 100%;
  min-height: 72px;
  padding: 12px 16px;
  display: grid;
  grid-template-columns: 72px minmax(0,1fr) auto;
  align-items: center;
  gap: 16px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  color: var(--text);
  text-align: left;
}
.reward-row:hover { background: rgba(255,255,255,.025); }
.reward-row-level { color: var(--faint); font: 600 12px/1.2 "DM Mono",monospace; }
.reward-row-copy { min-width: 0; }
.reward-row-copy strong { display: block; font-size: 14px; line-height: 1.4; }
.reward-row-copy small { display: block; margin-top: 4px; color: var(--ui-muted); font: 11px/1.5 "PingFang SC",sans-serif; }
.reward-row-state { color: var(--faint); font: 500 11px/1.2 "DM Mono",monospace; white-space: nowrap; }
.reward-row.is-claimable { border-left: 3px solid var(--gold); background: linear-gradient(90deg,rgba(235,202,125,.12),transparent 72%); }
.reward-row.is-claimable .reward-row-level,.reward-row.is-claimable .reward-row-state { color: var(--gold); }
.reward-row.is-claimed { opacity: .62; }
.reward-row.is-claimed .reward-row-state { color: var(--mint); }
.reward-row.is-locked { opacity: .46; }

.modal.is-gift-modal .modal-scroll { overflow: visible; }

@media (max-width: 1000px),(max-height: 560px) {
  .content-panel { padding-bottom: max(58px,calc(env(safe-area-inset-bottom) + 50px)); }
  .reward-list { margin-top: 12px; }
  .reward-row { min-height: 62px; padding: 9px 10px; grid-template-columns: 54px minmax(0,1fr) auto; gap: 10px; }
  .reward-row-copy strong { font-size: 13px; }
  .reward-row-copy small { font-size: 10px; }
  .reward-row-state { font-size: 10px; }
  .stage-dots b { font-size: 10px; }

  .modal.is-gift-modal .modal-header { min-height: 48px; padding: 8px 60px; }
  .modal.is-gift-modal .modal-close { top: 2px; right: 6px; }
  .modal.is-gift-modal .modal-scroll { padding: 0 16px; overflow: visible; }
  .modal.is-gift-modal .modal-intro { display: none; }
  .modal.is-gift-modal .gift-list { gap: 8px; }
  .modal.is-gift-modal .gift-row { min-height: 68px; grid-template-columns: 32px minmax(0,1fr); gap: 8px; padding: 7px 8px; }
  .modal.is-gift-modal .gift-symbol { width: 32px; height: 32px; }
  .modal.is-gift-modal .gift-row h3 { font-size: 12px; }
  .modal.is-gift-modal .gift-row p { margin-top: 2px; white-space: normal; font-size: 10px; line-height: 1.35; }
  .modal.is-gift-modal .range-control { margin: 6px 0; padding: 6px 12px; gap: 2px; }
  .modal.is-gift-modal .gift-preview { min-height: 32px; font-size: 11px; }
  .modal.is-gift-modal .gift-preview b { font-size: 12px; }
  .modal.is-gift-modal .modal-footer { padding: 8px 16px max(8px,env(safe-area-inset-bottom)); }
  .modal.is-gift-modal .modal-footer .primary-button { min-width: 220px; }
}

/* Detail corrections: 2026-09-02 */
.content-scroll-cue {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.content-scroll-cue:hover,
.content-scroll-cue:focus-visible { border: 0; background: transparent; }
.content-scroll-cue svg { width: 24px; height: 24px; stroke-width: 1.8; }

.secondary-tab,
.secondary-tab:hover,
.secondary-tab:focus,
.secondary-tab:active,
.secondary-tab.is-active {
  background: transparent;
  -webkit-tap-highlight-color: transparent;
}

.modal.is-gift-modal .range-control {
  padding-inline: 0;
  background: transparent;
}
