/* 星火：永夜幸存者 — 旗舰合作生存台面 */
.sv-shell {
  position: relative;
  width: 100%;
  height: min(76vh, 660px);
  min-height: 360px;
  overflow: hidden;
  border-radius: 18px;
  background: #05080a;
  color: #e9f1ec;
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  isolation: isolate;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .55), inset 0 0 0 1px rgba(178, 213, 200, .14);
}
.sv-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.sv-grain {
  position: absolute; inset: 0; pointer-events: none; opacity: .08; mix-blend-mode: overlay;
  background-image: repeating-linear-gradient(0deg, rgba(255,255,255,.16) 0 1px, transparent 1px 3px);
}
.sv-top {
  position: absolute; z-index: 4; top: 14px; left: 16px; right: 16px;
  display: flex; align-items: flex-start; gap: 18px; pointer-events: none;
}
.sv-brand { flex: 1; min-width: 0; }
.sv-eyebrow {
  display: block; font-size: 9px; letter-spacing: .22em; font-weight: 800;
  color: #86d9cb; text-transform: uppercase; text-shadow: 0 1px 8px rgba(0,0,0,.8);
}
.sv-brand b { display: block; margin-top: 3px; font-size: clamp(15px, 2.2vw, 22px); letter-spacing: -.02em; color: #f1f4e8; text-shadow: 0 2px 12px #000; }
.sv-brand small { display: block; margin-top: 2px; font-size: 10px; color: rgba(218, 231, 220, .58); }
.sv-clock, .sv-wave {
  min-width: 82px; padding: 8px 11px; text-align: right;
  background: linear-gradient(145deg, rgba(16, 25, 26, .78), rgba(8, 13, 14, .6));
  border: 1px solid rgba(147, 191, 178, .16); border-radius: 10px;
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.sv-clock small, .sv-wave small { display: block; font-size: 8px; letter-spacing: .14em; color: #9fc4b4; }
.sv-clock b { display: block; font-size: clamp(16px, 2.2vw, 25px); font-variant-numeric: tabular-nums; letter-spacing: .02em; color: #f4e8bd; }
.sv-wave b { display: inline-block; font-size: clamp(18px, 2.4vw, 28px); color: #f6d47b; line-height: 1; }
.sv-wave span { font-size: 10px; color: rgba(233,241,236,.45); }
.sv-party {
  position: absolute; z-index: 4; top: 78px; left: 16px;
  display: flex; flex-direction: column; gap: 5px; pointer-events: none;
}
.sv-member {
  display: flex; align-items: center; gap: 7px; min-width: 152px; max-width: 196px;
  padding: 5px 8px 5px 6px; border-left: 2px solid var(--pc, #ffd36a);
  background: linear-gradient(90deg, rgba(8,14,14,.78), rgba(8,14,14,.18));
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.sv-member i { color: var(--pc); font-style: normal; font-size: 9px; width: 10px; }
.sv-member > div { min-width: 0; flex: 1; }
.sv-member b { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 10px; color: #e6eee1; }
.sv-member small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; margin-top: 1px; font-size: 8px; color: rgba(203,220,205,.5); }
.sv-member span { font-size: 9px; color: rgba(233,241,236,.55); font-variant-numeric: tabular-nums; }
.sv-member.down { opacity: .52; filter: grayscale(.7); }
.sv-feed {
  position: absolute; z-index: 4; top: 84px; right: 16px; max-width: 230px;
  display: flex; flex-direction: column; gap: 3px; text-align: right; pointer-events: none;
}
.sv-feed span { font-size: 9px; line-height: 1.35; color: rgba(208, 228, 213, .48); text-shadow: 0 1px 4px #000; }
.sv-feed span:nth-last-child(-n+2) { color: rgba(235, 215, 156, .8); }
.sv-bossbar {
  position: absolute; z-index: 5; top: 58px; left: 50%; width: min(420px, 48vw); transform: translateX(-50%);
  display: none; flex-direction: column; gap: 4px; padding: 6px 10px;
  background: rgba(9, 10, 10, .66); border: 1px solid rgba(226, 112, 100, .28); border-radius: 8px;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.sv-bossbar.on { display: flex; }
.sv-bossbar small { align-self: center; font-size: 9px; font-weight: 800; letter-spacing: .18em; color: #e59b8d; }
.sv-bossbar i { height: 5px; background: rgba(255,255,255,.12); overflow: hidden; }
.sv-bossbar em { display: block; height: 100%; background: linear-gradient(90deg, #8f2f2c, #e25c4c 55%, #ffc078); transition: width .16s linear; }
.sv-bossbar b { align-self: flex-end; font-size: 8px; color: rgba(231, 205, 185, .6); font-variant-numeric: tabular-nums; }
.sv-hero {
  position: absolute; z-index: 4; left: 16px; bottom: 126px; width: min(280px, 44vw);
  padding: 10px 12px 9px; background: linear-gradient(145deg, rgba(12, 21, 19, .9), rgba(8, 12, 11, .72));
  border: 1px solid rgba(166, 204, 184, .16); border-radius: 12px;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  pointer-events: none; box-shadow: 0 10px 28px rgba(0,0,0,.34);
}
.sv-class { display: flex; align-items: baseline; gap: 7px; margin-bottom: 7px; }
.sv-class small { flex: 1; font-size: 8px; color: rgba(206, 226, 211, .44); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sv-class b { font-size: 11px; color: #f0e8cf; }
.sv-lv { margin-left: 5px; font-size: 9px; color: #e7c56a; }
.sv-hp { position: relative; height: 15px; background: rgba(0,0,0,.5); border: 1px solid rgba(189, 215, 196, .16); overflow: hidden; }
.sv-hp i { display: block; height: 100%; background: linear-gradient(90deg, #a64038, #de6d54 35%, #b9c96d 100%); transition: width .12s linear; }
.sv-hp span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: flex-end; padding-right: 5px; font-size: 9px; font-weight: 800; color: #eff8ea; text-shadow: 0 1px 3px #000; font-variant-numeric: tabular-nums; }
.sv-xp { display: flex; align-items: center; gap: 6px; margin-top: 5px; }
.sv-xp i { flex: 1; height: 4px; background: rgba(255,255,255,.12); overflow: hidden; }
.sv-xp em { display: block; height: 100%; background: #6ed8e2; box-shadow: 0 0 8px rgba(110,216,226,.5); transition: width .12s linear; }
.sv-xp small { font-size: 8px; color: rgba(205,230,216,.5); font-variant-numeric: tabular-nums; }
.sv-weapon { display: flex; align-items: baseline; gap: 6px; margin-top: 7px; padding-top: 6px; border-top: 1px solid rgba(183, 210, 191, .1); }
.sv-weapon span { color: #e6c36d; font-size: 12px; }
.sv-weapon b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 9px; color: #d7e3d4; }
.sv-weapon small { font-size: 8px; color: rgba(218, 232, 217, .46); }
.sv-stick {
  position: absolute; z-index: 6; left: 20px; bottom: 15px; width: 104px; height: 104px;
  border-radius: 50%; border: 1px solid rgba(172, 220, 202, .22);
  background: radial-gradient(circle at 50% 45%, rgba(60, 96, 86, .16), rgba(5, 10, 10, .38) 68%);
  touch-action: none; box-shadow: inset 0 0 0 5px rgba(5, 10, 10, .2), 0 4px 18px rgba(0,0,0,.3);
}
.sv-stick i {
  position: absolute; left: 50%; top: 50%; width: 40px; height: 40px; margin: -20px 0 0 -20px;
  border-radius: 50%; background: radial-gradient(circle at 38% 30%, #d9e8cf, #81957e 38%, #35473f 72%);
  box-shadow: 0 4px 14px rgba(0,0,0,.55), inset 0 1px 2px rgba(255,255,255,.35);
  pointer-events: none;
}
.sv-stick em { position: absolute; left: 50%; top: 50%; width: 7px; height: 7px; margin: -3.5px; border-radius: 50%; background: #9fe6cf; opacity: .6; }
.sv-stick small { position: absolute; left: 50%; bottom: -17px; transform: translateX(-50%); font-size: 8px; color: rgba(219, 235, 220, .33); white-space: nowrap; }
.sv-actions { position: absolute; z-index: 7; right: 18px; bottom: 22px; display: flex; align-items: flex-end; gap: 9px; }
.sv-dash {
  width: 76px; height: 76px; border-radius: 50%; cursor: pointer;
  border: 1px solid rgba(255, 210, 112, .46); background: radial-gradient(circle at 37% 27%, rgba(255,236,172,.35), rgba(96,73,31,.72) 52%, rgba(23,26,20,.9));
  color: #f4e4b0; font: inherit; font-weight: 900; font-size: 12px; letter-spacing: .08em;
  box-shadow: 0 0 0 5px rgba(255, 207, 100, .05), 0 8px 24px rgba(0,0,0,.38);
  transition: transform .12s ease, filter .12s;
}
.sv-dash b { display: block; }
.sv-dash small { display: block; margin-top: 3px; font-size: 7px; letter-spacing: .12em; color: rgba(255,238,190,.55); font-weight: 600; }
.sv-dash:active { transform: scale(.9); filter: brightness(1.18); }
.sv-dash.cooling { filter: grayscale(.55) brightness(.72); }
.sv-help {
  width: 30px; height: 30px; border-radius: 50%; border: 1px solid rgba(173, 211, 192, .24);
  background: rgba(8, 14, 13, .52); color: rgba(223, 236, 223, .7); font: inherit; font-size: 13px; cursor: pointer;
}
.sv-upgrades { position: absolute; z-index: 20; inset: 0; display: none; align-items: center; justify-content: center; padding: 20px; background: radial-gradient(circle at 50% 45%, rgba(4,10,10,.4), rgba(2,5,6,.9)); backdrop-filter: blur(2px); }
.sv-upgrades.on { display: flex; }
.sv-up-card { width: min(760px, 94vw); padding: 18px 20px 20px; border: 1px solid rgba(193, 226, 203, .18); border-radius: 18px;
  background: linear-gradient(150deg, rgba(22, 33, 29, .96), rgba(8, 13, 12, .94));
  box-shadow: 0 26px 80px rgba(0,0,0,.58), inset 0 1px rgba(255,255,255,.08); }
.sv-up-card > span { color: #8ce3d2; }
.sv-up-card h3 { margin: 5px 0 0; font-size: clamp(18px, 2.6vw, 26px); letter-spacing: -.03em; color: #f5f1d6; }
.sv-up-card p { margin: 5px 0 15px; font-size: 11px; color: rgba(210, 228, 214, .55); }
.sv-up-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.sv-up {
  position: relative; min-height: 122px; padding: 13px 13px 28px; text-align: left; cursor: pointer;
  border: 1px solid rgba(169, 211, 184, .18); border-radius: 12px;
  background: linear-gradient(160deg, rgba(43, 65, 54, .5), rgba(11, 17, 15, .8));
  color: #e9f1e6; font: inherit; transition: transform .13s, border-color .13s, background .13s;
}
.sv-up:hover, .sv-up:focus-visible { transform: translateY(-3px); border-color: rgba(244, 212, 120, .55); background: linear-gradient(160deg, rgba(73, 93, 57, .56), rgba(18, 24, 18, .86)); outline: none; }
.sv-up > span { display: block; font-size: 19px; color: #e8c56c; line-height: 1; margin-bottom: 9px; }
.sv-up b { display: block; font-size: 13px; color: #f5efd5; }
.sv-up small { display: block; margin-top: 5px; font-size: 9px; line-height: 1.45; color: rgba(213, 232, 216, .58); }
.sv-up em { position: absolute; left: 12px; bottom: 9px; font-size: 8px; color: rgba(182, 208, 185, .36); font-style: normal; letter-spacing: .12em; }
.sv-up::after { content: ""; position: absolute; right: 10px; top: 10px; width: 5px; height: 5px; border-top: 1px solid #e8c56c; border-right: 1px solid #e8c56c; opacity: .5; }
.sv-result { position: absolute; z-index: 30; inset: 0; display: none; align-items: center; justify-content: center; padding: 20px; background: rgba(2,5,6,.74); backdrop-filter: blur(5px); }
.sv-result.on { display: flex; }
.sv-end { width: min(520px, 92vw); padding: 22px 24px; border-radius: 18px; border: 1px solid rgba(206, 229, 209, .18);
  background: linear-gradient(155deg, rgba(23, 34, 29, .98), rgba(7, 11, 10, .96)); box-shadow: 0 30px 90px rgba(0,0,0,.65); }
.sv-end.win { border-color: rgba(236, 203, 105, .38); }
.sv-end.lose { border-color: rgba(208, 91, 80, .32); }
.sv-end > span { color: #e3c471; }
.sv-end h2 { margin: 7px 0 3px; font-size: clamp(27px, 4vw, 42px); line-height: 1; letter-spacing: -.04em; color: #f7f0d3; }
.sv-end.lose h2 { color: #e7aaa0; }
.sv-end p { margin: 7px 0 16px; font-size: 12px; color: rgba(210, 227, 212, .56); }
.sv-end-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-bottom: 17px; }
.sv-end-stats div { padding: 9px 10px; background: rgba(4, 9, 8, .5); border: 1px solid rgba(182, 213, 189, .1); }
.sv-end-stats small { display: block; font-size: 8px; color: rgba(202, 223, 207, .4); letter-spacing: .08em; }
.sv-end-stats b { display: block; margin-top: 4px; font-size: 15px; color: #efdb9d; }
.sv-end-actions { display: flex; gap: 9px; }
.sv-btn { flex: 1; padding: 11px 12px; border-radius: 9px; border: 1px solid rgba(183, 215, 193, .22); background: rgba(11,18,15,.7); color: #dbe9db; font: inherit; font-size: 12px; font-weight: 800; cursor: pointer; }
.sv-btn.primary { background: linear-gradient(135deg, #d9b35c, #a87c35); border-color: #f0d194; color: #1c2118; }
.sv-btn:active { transform: scale(.97); }
.sv-toast { position: absolute; z-index: 50; left: 50%; bottom: 24%; transform: translateX(-50%) translateY(8px); max-width: 78%; padding: 8px 12px; border-radius: 8px; background: rgba(8, 13, 12, .9); border: 1px solid rgba(181, 218, 195, .2); color: #e6f1e2; font-size: 10px; opacity: 0; pointer-events: none; transition: opacity .18s, transform .18s; }
.sv-toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (max-width: 760px) {
  .sv-shell { height: min(72vh, 580px); min-height: 330px; border-radius: 12px; }
  .sv-top { top: 9px; left: 10px; right: 10px; gap: 8px; }
  .sv-brand b { font-size: 13px; }
  .sv-brand small { display: none; }
  .sv-clock, .sv-wave { min-width: 64px; padding: 6px 7px; }
  .sv-clock b { font-size: 14px; }
  .sv-wave b { font-size: 18px; }
  .sv-party { top: 56px; left: 10px; }
  .sv-member { min-width: 122px; max-width: 148px; padding: 4px 6px; }
  .sv-member b { font-size: 9px; }
  .sv-member small { font-size: 7px; }
  .sv-feed { display: none; }
  .sv-hero { left: 10px; bottom: 102px; width: min(244px, 62vw); padding: 8px 9px; }
  .sv-stick { width: 88px; height: 88px; left: 14px; bottom: 12px; }
  .sv-stick i { width: 34px; height: 34px; margin: -17px 0 0 -17px; }
  .sv-actions { right: 12px; bottom: 12px; }
  .sv-dash { width: 62px; height: 62px; font-size: 10px; }
  .sv-help { width: 25px; height: 25px; font-size: 11px; }
  .sv-up-card { padding: 12px; }
  .sv-up-grid { gap: 7px; }
  .sv-up { min-height: 94px; padding: 9px 9px 24px; }
  .sv-up > span { font-size: 16px; margin-bottom: 6px; }
  .sv-up b { font-size: 11px; }
  .sv-up small { font-size: 8px; }
  .sv-bossbar { top: 48px; width: 64vw; }
}
body.landscape-mode:has(.g-live:not(.g-live-done)) .sv-shell { height: 100%; min-height: 0; border-radius: 0; }
body.landscape-mode:has(.g-live:not(.g-live-done)) .sv-stick { bottom: 12px; }
body.landscape-mode:has(.g-live:not(.g-live-done)) .sv-actions { bottom: 12px; }
@media (orientation: landscape) and (max-height: 500px) {
  .sv-shell { height: 100%; min-height: 0; border-radius: 0; }
  .sv-top { top: 6px; left: 10px; right: 104px; }
  .sv-brand b { font-size: 12px; }
  .sv-brand small { display: none; }
  .sv-party { top: 46px; }
  .sv-feed { top: 46px; }
  .sv-hero { bottom: 88px; width: 220px; padding: 7px 9px; }
  .sv-stick { width: 80px; height: 80px; bottom: 10px; left: 12px; }
  .sv-dash { width: 58px; height: 58px; }
  .sv-up-card { width: min(680px, 86vw); padding: 12px 14px 14px; }
  .sv-up-grid { gap: 7px; }
  .sv-up { min-height: 88px; padding: 9px 9px 22px; }
  .sv-up > span { font-size: 15px; margin-bottom: 4px; }
  .sv-up b { font-size: 11px; }
  .sv-up small { font-size: 8px; }
}
