.game-card .hsr-sim-link { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px; padding: 0 14px; border: 1px solid var(--glass-border); border-radius: 12px; color: var(--text-primary); background: rgba(255, 255, 255, 0.05); font: inherit; font-size: .85rem; font-weight: 800; text-decoration: none; margin-right: auto; }
.game-card .hsr-sim-link:hover { background: rgba(255, 255, 255, 0.1); }
body.light-mode .game-card .hsr-sim-link { background: rgba(255, 255, 255, 0.9); color: #475569; border-color: rgba(0, 0, 0, 0.2); }
body.light-mode .game-card .hsr-sim-link:hover { background: #ffffff; color: #000; }
.hsr-modal-open { overflow: hidden; }
.hsr-simulator { --hsr-accent: #60a5fa; color: var(--text-primary, #fff); background: var(--bg-color, #0d0e12); border: 1px solid var(--glass-border, #ffffff20); border-radius: 16px; width: min(1080px, calc(100vw - 40px)); max-height: calc(100dvh - 40px); padding: 0; margin: auto; box-shadow: 0 24px 100px #0009; overscroll-behavior: contain; }
.hsr-simulator::backdrop { background: #030710c9; backdrop-filter: blur(8px); }
.hsr-simulator { max-width: calc(100vw - 40px); }
.hsr-simulator button, .hsr-simulator select { font: inherit; }
.hsr-simulator button, .hsr-simulator summary, .hsr-simulator select { cursor: pointer; }
.hsr-simulator :focus-visible, .hsr-sim-link:focus-visible { outline: 3px solid #60a5fa; outline-offset: 3px; }
.hsr-topbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 20px 24px; border-bottom: 1px solid var(--glass-border); }
.hsr-eyebrow { font-size: .65rem; letter-spacing: .16em; color: var(--text-secondary); font-weight: 800; }
.hsr-topbar h2 { margin: 6px 0 0; font-size: 1.1rem; }
.hsr-topbar h2 span { color: var(--text-secondary); font-size: .85rem; margin-left: 8px; }
.hsr-close { width: 44px; height: 44px; border: 1px solid var(--glass-border); background: var(--card-bg); color: var(--text-primary); border-radius: 12px; flex-shrink: 0; }
.hsr-body { padding: 20px 24px; }
.hsr-trial-label { font-size: .72rem; color: var(--text-secondary); margin-bottom: 14px; line-height: 1.6; }
.hsr-toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.hsr-toolbar label { font-size: .8rem; font-weight: 700; color: var(--text-secondary); }
.hsr-toolbar select { min-width: 0; max-width: 240px; flex: 1; min-height: 44px; padding: 8px 32px 8px 12px; color: var(--text-primary); background: var(--bg-color); border: 1px solid var(--glass-border); border-radius: 8px; }
.hsr-currency { display: flex; align-items: center; gap: 8px; margin-left: auto; font-size: .8rem; white-space: nowrap; }
.hsr-currency > span { color: #f6ca78; font-size: 1.4rem; }
.hsr-currency b { font-size: 1.6rem; margin-left: 6px; }
.hsr-currency img, .hsr-pull-actions small img { object-fit: contain; vertical-align: middle; }
.hsr-pull-actions button small { display: flex; justify-content: center; align-items: center; gap: 4px; }
.hsr-rateups { position: absolute; right: 24px; bottom: 24px; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; padding: 0; margin: 0; border: 0; background: transparent; color: #fff; text-shadow: 0 2px 5px #000, 0 0 3px #000; }
.hsr-rateups h3 { font-size: .72rem; white-space: nowrap; }
.hsr-rateups p { color: var(--text-secondary); font-size: .7rem; margin-top: 6px; }
.hsr-rateup-list { display: flex; gap: 10px; }
.hsr-rateup-list > div { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 2px; font-size: .72rem; font-weight: 700; }
.hsr-rateup-list img { width: 36px; height: 44px; object-fit: contain; }
.hsr-rateup-list small { display: block; color: #c084fc; letter-spacing: .06em; font-size: .6rem; margin-top: 4px; }
.hsr-pool { margin-top: 16px; border: 1px solid var(--glass-border); border-radius: 10px; font-size: .8rem; }
.hsr-pool summary { cursor: pointer; padding: 14px; min-height: 44px; }
.hsr-pool-content { padding: 0 14px 14px; }
.hsr-pool-content h4 { margin: 16px 0 10px; font-size: .8rem; }
.hsr-pool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(85px, 1fr)); gap: 10px; }
.hsr-pool-grid figure { text-align: center; padding: 8px 4px; border-radius: 8px; background: var(--card-bg); border: 1px solid var(--glass-border); }
.hsr-pool-grid img { object-fit: contain; }
.hsr-pool-grid figcaption { font-size: .7rem; line-height: 1.5; margin-top: 4px; overflow-wrap: anywhere; }
.hsr-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, 1fr); gap: 16px; }
.hsr-stage { display: flex; flex-direction: column; position: relative; isolation: isolate; min-height: 390px; overflow: hidden; border-radius: 12px; background: #162337; border: 1px solid #60a5fa33; color: #fff; }
.hsr-art, .hsr-art-shade { position: absolute; inset: 0; width: 100%; height: 100%; }
.hsr-art { object-fit: cover; }
.hsr-art-shade { background: linear-gradient(0deg, #09101cf5, #09101c11 80%), linear-gradient(90deg, #09101ca8, transparent); }
.hsr-banner-copy { position: absolute; left: 24px; right: 180px; bottom: 24px; text-shadow: 0 2px 8px #000; }
.hsr-chip { display: inline-block; border: 1px solid #ffffff40; background: #0d0e12b0; padding: 5px 9px; border-radius: 6px; font-size: .7rem; }
.hsr-banner-title { font-size: .9rem; margin: 14px 0 4px; }
.hsr-character { font-size: clamp(1.6rem, 3vw, 2.5rem); font-weight: 900; overflow-wrap: anywhere; }
.hsr-gold { color: #f6ca78; font-size: 1.2rem; letter-spacing: .1em; margin-top: 4px; }
.hsr-dates { font-size: .72rem; margin-top: 12px; }
.hsr-stage-caption { position: absolute; bottom: 0; left: 0; right: 0; padding: 15px 24px; font-size: .78rem; border-top: 1px solid #ffffff20; background: #09101c80; }
.hsr-panel { padding: 22px; background: var(--card-bg); border: 1px solid var(--glass-border); border-radius: 12px; }
.hsr-panel h3 { font-size: .95rem; margin-top: 8px; }
.hsr-total { display: flex; align-items: baseline; gap: 10px; margin: 12px 0 16px; }
.hsr-total strong { font-size: 2.6rem; font-variant-numeric: tabular-nums; line-height: 1.2; }
.hsr-total span { color: var(--text-secondary); font-size: .8rem; }
.hsr-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.hsr-stats div { display: flex; flex-direction: column; gap: 6px; }
.hsr-stats span { color: var(--text-secondary); font-size: .65rem; }
.hsr-stats strong { font-size: 1rem; }
.hsr-pity { margin: 20px 0; }
.hsr-pity > div { display: flex; justify-content: space-between; font-size: .72rem; gap: 8px; }
.hsr-pity progress { width: 100%; height: 6px; border: 0; border-radius: 8px; margin: 10px 0; accent-color: #60a5fa; }
.hsr-pity progress::-webkit-progress-bar { background: #64748b40; border-radius: 8px; }
.hsr-pity progress::-webkit-progress-value { background: #60a5fa; border-radius: 8px; }
.hsr-pity p { font-size: .78rem; color: var(--text-secondary); }
.hsr-pity .is-guaranteed { color: var(--text-primary); font-weight: 800; }
.hsr-pull-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hsr-pull-actions button { min-height: 62px; border-radius: 10px; border: 1px solid var(--glass-border); background: var(--card-bg); color: var(--text-primary); font-weight: 800; transition: transform 150ms; }
.hsr-pull-actions button:hover { transform: translateY(-2px); }
.hsr-pull-actions button:active { transform: translateY(0); }
.hsr-pull-actions .hsr-primary { background: #60a5fa; color: #0d0e12; border-color: #60a5fa; }
.hsr-pull-actions small { display: block; font-size: .7rem; font-weight: 500; margin-top: 4px; }
.hsr-note { font-size: .68rem; line-height: 1.6; color: var(--text-secondary); margin-top: 12px; }
.hsr-results-section { margin-top: 24px; }
.hsr-section-heading { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; align-items: center; margin-bottom: 12px; }
.hsr-section-heading h3 { font-size: .9rem; }
.hsr-section-heading > span { color: var(--text-secondary); font-size: .72rem; }
.hsr-results { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 8px; }
.hsr-empty { grid-column: 1 / -1; min-height: 150px; display: flex; justify-content: center; align-items: center; gap: 20px; border: 1px dashed var(--glass-border); border-radius: 12px; color: var(--text-secondary); font-size: .8rem; line-height: 1.8; }
.hsr-empty > span { font-size: 3rem; color: var(--hsr-accent); }
.hsr-result { position: relative; min-height: 154px; overflow: hidden; border-radius: 8px; border: 1px solid #64748b70; background: #162337; color: #fff; animation: hsr-reveal 250ms both; animation-delay: calc(var(--reveal-order) * 25ms); }
.hsr-result > img { position: absolute; width: 100%; height: 100%; object-fit: cover; }
.hsr-result.has-item-art { min-height: 180px; }
.hsr-result.has-item-art > img { top: 4px; height: 116px; object-fit: contain; }
.hsr-result-symbol { position: absolute; top: 12px; left: 0; width: 100%; text-align: center; font-size: 2.5rem; color: #93b8ec; }
.hsr-result-copy { position: absolute; inset: auto 0 0; display: flex; flex-direction: column; gap: 5px; padding: 24px 6px 9px; background: linear-gradient(transparent, #0d0e12e8 28%); text-align: center; }
.hsr-result-copy strong { font-size: .66rem; line-height: 1.45; overflow-wrap: anywhere; }
.hsr-result-copy small { font-size: .52rem; letter-spacing: .04em; color: #cbd5e1; }
.hsr-result-copy > span { font-size: .65rem; color: #9ebceb; }
.hsr-result.rarity-4 { border-color: #c084fc; background: #332447; }
.hsr-result.rarity-4 .hsr-result-copy > span { color: #d8b4fe; }
.hsr-result.rarity-5 { border-color: #f6ca78; background: #4b3c24; }
.hsr-result.rarity-5 .hsr-result-copy > span, .hsr-result.rarity-5 small { color: #f6ca78; }
.hsr-history, .hsr-rules { margin-top: 16px; border: 1px solid var(--glass-border); border-radius: 10px; font-size: .8rem; }
.hsr-history summary, .hsr-rules summary { padding: 14px; min-height: 44px; }
.hsr-history summary span { margin-left: 8px; color: var(--text-secondary); }
.hsr-history ol { list-style: none; padding: 0 14px 14px; max-height: 230px; overflow-y: auto; }
.hsr-history li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding: 10px 0; border-top: 1px solid var(--glass-border); font-size: .75rem; }
.hsr-history li span { color: var(--text-secondary); }
.hsr-bottom { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 12px; font-size: .73rem; color: var(--text-secondary); }
.hsr-reset, .hsr-reset-confirm button { min-height: 44px; padding: 8px 12px; color: var(--text-primary); border: 1px solid var(--glass-border); border-radius: 8px; background: var(--card-bg); flex-shrink: 0; }
.hsr-reset-confirm { margin-top: 12px; padding: 16px; border: 1px solid #60a5fa; border-radius: 10px; }
.hsr-reset-confirm p { font-size: .8rem; margin-bottom: 12px; }
.hsr-reset-confirm button + button { margin-left: 8px; }
.hsr-rules { color: var(--text-secondary); }
.hsr-rules > div { padding: 0 14px 14px; line-height: 1.8; }
.hsr-rules p + p { margin-top: 8px; }
.hsr-rules a { color: var(--text-primary); display: inline-block; margin-top: 12px; text-underline-offset: 4px; }
.hsr-disclaimer { text-align: center; color: var(--text-secondary); font-size: .68rem; margin-top: 16px; }
@keyframes hsr-reveal { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 768px) {
    .hsr-simulator { width: calc(100vw - 16px); max-width: calc(100vw - 16px); max-height: calc(100dvh - 16px); border-radius: 12px; }
    .hsr-topbar { padding: 14px 16px; }
    .hsr-body { padding: 16px; }
    .hsr-topbar h2 { font-size: .95rem; }
    .hsr-topbar h2 span { display: block; margin: 4px 0 0; font-size: .75rem; }
    .hsr-layout { grid-template-columns: 1fr; }
    .hsr-stage { min-height: 340px; }
    .hsr-banner-copy { left: 20px; right: 154px; bottom: 20px; }
    .hsr-banner-title { margin-top: 8px; }
    .hsr-stage-caption { padding: 12px 20px; }
    .hsr-panel { padding: 18px; }
    .hsr-toolbar { flex-wrap: wrap; gap: 8px; }
    .hsr-toolbar label { width: 100%; }
    .hsr-toolbar select { max-width: none; width: 150px; }
    .hsr-currency { font-size: .72rem; gap: 4px; }
    .hsr-currency b { margin-left: 2px; }
    .hsr-results { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
    .hsr-result { min-height: 138px; }
    .hsr-result-copy { padding-left: 3px; padding-right: 3px; }
    .hsr-result-copy strong { font-size: .6rem; }
    .hsr-result-copy > span { font-size: .56rem; }
    .hsr-rateups { right: 16px; bottom: 20px; padding: 0; gap: 6px; }
    .hsr-rateup-list { gap: 6px; }
    .hsr-rateup-list > div { flex-direction: column; gap: 3px; text-align: center; font-size: .65rem; }
    .hsr-rateup-list img { width: 36px; height: 44px; }
    .hsr-result.has-item-art { min-height: 174px; }
    .hsr-result.has-item-art > img { height: 102px; }
    .hsr-bottom { font-size: .65rem; }
}
@media (prefers-reduced-motion: reduce) { .hsr-result { animation: none; } .hsr-pull-actions button { transition: none; } }
