/* v64.44: shared reference presentation; no gameplay or checkout-policy changes. */
#app .chain-evolution-overlay { position: fixed; z-index: 91; }
#app .chain-evolution-card { text-align: center; }
.evolution-emblem { display: grid; place-items: center; width: 76px; height: 76px; margin: 6px auto 18px; color: var(--spark-gold); font-size: 34px; border: 1px solid #eac04b99; border-radius: 23px; background: radial-gradient(circle at top,#664917,#17132b); box-shadow: 0 0 28px #ffc10722; }
#app .spark-dialog .evolution-detail, #app .spark-dialog .voltage-split-intro { color: var(--feedback-copy); font-size: 16px; line-height: 1.4; font-weight: 400; }
#app .spark-dialog :is(.evolution-continue,.stars-confirm,.voltage-split-choices) { flex: 0 0 auto; width: 100%; position: relative; margin-top: 16px; }
#app .spark-dialog .voltage-split-modal { text-align: center; }
#app .voltage-split-modal::before { display: none; }
#app .voltage-split-core { margin: 5px auto 16px; flex-shrink: 0; }
#app .voltage-split-note { color: #a8bed8; font-size: 12px; line-height: 1.4; margin: 0 0 8px; }
#app .voltage-split-choices { gap: 10px; }
#app .voltage-choice { min-width: 0; min-height: 126px; padding: 12px 8px; border-radius: 15px; }
#app .voltage-choice.stabilize { background: linear-gradient(145deg,#075746,#02332e 60%,#041c27); border-color: #00ebba; }
#app .voltage-choice.overcharge { background: linear-gradient(145deg,#851446,#4e0b2e 60%,#1d0c2d); border-color: #ff2d86; }
#app .voltage-choice :is(small,b) { font-size: 12px; line-height: 1.3; white-space: normal; letter-spacing: 0; }
#app .voltage-choice strong { font-size: 15px; line-height: 1.2; letter-spacing: 0; overflow-wrap: normal; }
#app .voltage-choice-icon { width: 30px; height: 30px; border: 0; box-shadow: none; background: transparent; font-size: 26px; }
#app .stars-checkout-card .feedback-scroll { display: block; padding-top: 12px; }
#app .stars-checkout-card .stars-checkout-close { z-index: 5; }
#app .stars-checkout-card .feedback-scroll > .eyebrow { text-align: center; }
#app .stars-checkout-card .feedback-scroll > h2 { font-size: 28px; line-height: 1.15; text-align: center; margin: 8px 0 12px; }
#app .stars-checkout-card .stars-checkout-detail { font-size: 16px; line-height: 1.4; }
#app .stars-checkout-card .stars-confirm:disabled { background: #1a263d; color: #a8bbd8; border-color: #344766; box-shadow: none; }
#app .stars-checkout-card .stars-confirm:disabled :is(.button-copy,.button-meta) { color: #a8bbd8; }
#app .stars-checkout-card .stars-legal { display: block; font-size: 12px; line-height: 1.4; margin: 12px 0 0; color: #aec5e4; }
#app .stars-checkout-card .stars-terms { height: auto; }
#app .stars-checkout-card .stars-terms-link { min-height: 44px; }
#app .reference-incoming-screen {
  display: flex; flex-direction: column; width: 100%; min-height: 0; box-sizing: border-box;
  height: calc(var(--tg-viewport-stable-height, var(--spark-viewport-height)) - var(--spark-safe-top) - var(--spark-safe-bottom) - var(--spark-top-chrome) - 24px);
  margin: 12px 0; padding: 16px; overflow: hidden; text-align: center;
  background: #020813; border: 1px solid var(--feedback-edge); border-radius: 20px;
}
.incoming-scroll { min-height: 0; flex: 1 1 auto; overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.incoming-details { margin: 12px 0; text-align: left; border: 1px solid var(--feedback-edge); border-radius: 12px; background: #061526; }
.incoming-details summary { display: flex; justify-content: space-between; align-items: center; min-height: 44px; padding: 12px; cursor: pointer; font-size: 14px; color: var(--feedback-copy); }
.incoming-details summary::-webkit-details-marker { display: none; }
.incoming-details summary::after { content: "+"; }
.incoming-details[open] summary::after { content: "−"; }
.incoming-details > :not(summary) { margin-inline: 8px; }
#app .reference-incoming-screen h1 { font: 700 28px/1.15 var(--spark-font-ui); letter-spacing: -.02em; overflow-wrap: anywhere; margin: 7px 0 10px; }
#app .reference-incoming-screen .eyebrow { color: #72cfff; font-size: 12px; line-height: 16px; margin: 2px 0 5px; }
#app .reference-incoming-screen .muted { font-size: 14px; color: var(--feedback-copy); }
#app .reference-incoming-screen .incoming-challenge { position: relative; z-index: 8; background: #061526; }
#app .reference-incoming-screen :is(.incoming-challenge span,.incoming-pulse small,.chain-legacy p,.chain-goal p) { font-size: 12px; line-height: 1.4; color: var(--feedback-copy); }
#app .reference-incoming-screen :is(.incoming-challenge strong,.incoming-pulse b) { font-size: 16px; line-height: 1.3; }
#app .reference-incoming-screen .reference-scene { --backdrop-rise: 0px; min-height: 230px; height: 230px; margin: 8px 0 0; overflow: hidden; border-radius: 0; }
#app .reference-incoming-screen .reference-character { bottom: 2%; width: 90%; height: 94%; }
.incoming-action-panel { flex: 0 0 auto; position: relative; z-index: 9; padding-top: 12px; background: #020813; }
#app .incoming-action-panel .danger-head { font-size: 14px; margin: 0 0 8px; }
#app .incoming-action-panel .danger-head strong { font-size: 28px; color: #fff; }
#app .incoming-action-panel .danger-track { height: 10px; }
#app .incoming-action-panel .danger-fill { background: var(--spark-risk-fill); box-shadow: 0 0 12px #ff141966; }
#app .incoming-action-panel .danger-note { margin: 8px 0; font-size: 12px; color: #b5d5fb; }
#app .incoming-action-panel .primary-button { width: 100%; min-height: 60px; padding: 12px; border-radius: 14px; background: var(--spark-primary-fill); border: 1px solid #ba8bffb0; }
#app .incoming-action-panel .button-copy { font-size: 19px; line-height: 1.2; letter-spacing: 0; }
#app .incoming-action-panel .button-meta { font-size: 12px; line-height: 1.3; letter-spacing: 0; }
/* Keep short status messages outside dialog controls. Long messages can scroll. */
body:not(.onboarding-open):has(.spark-dialog):has(#toast.show) #app .spark-dialog { padding-top: calc(var(--spark-safe-top, 0px) + 88px); }
body:not(.onboarding-open):has(.spark-dialog) #toast.show { top: calc(var(--spark-safe-top, 0px) + 12px); bottom: auto; z-index: 200; max-height: 64px; overflow: auto; pointer-events: auto; transform: none; transition: opacity .15s ease; }
@media (max-width: 360px) {
  #app .voltage-split-choices { grid-template-columns: 1fr; gap: 8px; }
  #app .voltage-choice { min-height: 82px; padding: 10px; }
  #app .voltage-choice-icon { display: none; }
  #app .voltage-choice strong { font-size: 17px; }
}
@media (max-height: 500px) {
  #app .voltage-choice { min-height: 98px; padding: 8px; }
  #app .voltage-choice-icon { display: none; }
  #app .reference-incoming-screen { padding: 12px; }
  #app .incoming-action-panel { padding-top: 6px; }
}
@media (prefers-reduced-motion: reduce) { #app .reference-incoming-screen, #app .reference-incoming-screen * { animation: none !important; transition: none !important; } }
