.gv2 {
	box-sizing: border-box; width: min(1400px, calc(100vw - 32px)); height: min(960px, calc(100dvh - 32px));
	max-width: none; max-height: none; padding: 0; border: 1px solid #586078; border-radius: 10px;
	background: #272a31; color: #e5e9ff; font: 14px/1.4 system-ui, sans-serif; overflow: hidden;
}
.gv2[open] { display: grid; grid-template-rows: auto auto minmax(0, 1fr); }
.gv2::backdrop { background: #000b; }
.gv2 *, .gv2 *::before { box-sizing: border-box; }
.gv2 :is(button, input, select) { font: inherit; color: inherit; }
.gv2 :is(button, select, input:not([type="range"])) { min-height: 36px; border: 1px solid #586078; border-radius: 7px; background: #171a23; padding: 6px 9px; }
.gv2 button { cursor: pointer; touch-action: manipulation; }
.gv2 button:hover:not(:disabled) { border-color: #b9a2ff; background: #342b4c; }
.gv2 button:disabled { opacity: .45; cursor: default; }
.gv2 :is(button, input, select, canvas, [tabindex]):focus-visible { outline: 2px solid #b9a2ff; outline-offset: -2px; }
.gv2 .gv2-primary, .gv2 button[aria-pressed="true"] { background: #634395; border-color: #b9a2ff; color: #fff; }
.gv2-header { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; gap: 8px; border-bottom: 1px solid #42495e; }
.gv2-brand { display: flex; gap: 10px; align-items: center; min-width: 0; }
.gv2-mark { display: grid; place-items: center; background: #342b4c; color: #d9c4ff; width: 40px; height: 40px; border-radius: 8px; font-size: 22px; }
.gv2-eyebrow { font-size: 10px; letter-spacing: 1px; color: #b9a2ff; }
.gv2 h2 { margin: 0; font-size: 18px; }
.gv2 h2 span { font-size: 12px; color: #b9a2ff; }
.gv2 h3 { margin: 0; font-size: 14px; }
.gv2-setup { display: flex; flex-wrap: wrap; align-items: end; gap: 8px; padding: 10px 16px; border-bottom: 1px solid #42495e; }
.gv2-setup label { display: grid; gap: 3px; min-width: 0; font-size: 12px; color: #cbd3e8; }
.gv2-setup label:first-child { flex: 1; min-width: 150px; }
.gv2-setup :is(input, select) { max-width: 100%; min-width: 0; }
.gv2-seed { width: 115px; }
.gv2-status { font-size: 12px; color: #b9a2ff; align-self: center; }
.gv2-content { min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 10px; padding: 10px; }
.gv2-main { min-width: 0; min-height: 0; overflow: auto; display: grid; align-content: start; gap: 10px; }
.gv2-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.gv2-card { background: #171a23; padding: 8px; border: 1px solid #42495e; border-radius: 7px; display: grid; gap: 3px; min-width: 0; }
.gv2-card span { font-size: 11px; color: #aebbd4; }
.gv2-card strong { font-size: 18px; overflow-wrap: anywhere; }
.gv2-card small { color: #aebbd4; font-size: 11px; }
.gv2-chart-panel, .gv2-roster, .gv2-log { border: 1px solid #42495e; border-radius: 7px; background: #20232c; padding: 8px; min-width: 0; }
.gv2-chart-heading, .gv2-section-heading { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 6px; }
.gv2-tabs, .gv2-zoom, .gv2-filters { display: flex; flex-wrap: wrap; gap: 4px; }
.gv2-legend { display: flex; flex-wrap: wrap; gap: 4px; margin: 8px 0; }
.gv2-legend button { border-left: 3px solid var(--series-color); font-size: 12px; }
.gv2-legend button[aria-pressed="false"] { opacity: .55; text-decoration: line-through; }
.gv2-canvas-wrap { position: relative; min-width: 0; height: clamp(200px, 32vh, 360px); }
.gv2 canvas { display: block; width: 100%; height: 100%; touch-action: none; border-radius: 5px; background: #171a23; }
.gv2-tooltip { position: absolute; pointer-events: none; max-width: calc(100% - 8px); padding: 8px; background: #171a23ee; border: 1px solid #586078; border-radius: 7px; font-size: 12px; }
.gv2-empty { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; padding: 20px; color: #aebbd4; }
.gv2 [hidden] { display: none !important; }
.gv2-chart-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px; font-size: 11px; color: #aebbd4; padding-top: 5px; }
.gv2-transport { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.gv2-time { font-size: 12px; font-variant-numeric: tabular-nums; }
.gv2-scrub { flex: 1; min-width: 100px; accent-color: #b9a2ff; }
.gv2-speed-label { display: flex; align-items: center; gap: 5px; font-size: 12px; }
.gv2-section-heading > span { color: #aebbd4; font-size: 11px; }
.gv2-players { display: grid; gap: 5px; margin-top: 8px; }
.gv2-player { display: grid; grid-template-columns: minmax(80px, 1fr) 1fr 1fr auto; align-items: center; gap: 8px; padding: 6px; background: #171a23; border-left: 3px solid var(--series-color); font-size: 12px; }
.gv2-player strong { overflow-wrap: anywhere; }
.gv2-resource { min-width: 0; font-size: 11px; }
.gv2-resource > div { height: 4px; background: #42495e; margin-top: 3px; }
.gv2-resource i { display: block; height: 100%; background: #e38492; }
.gv2-en i { background: #93caff; }
.gv2-log { min-height: 0; display: grid; grid-template-rows: auto auto auto minmax(0, 1fr) auto; gap: 8px; }
.gv2-search { width: 100%; min-width: 0; }
.gv2-filters button { font-size: 12px; padding-inline: 6px; }
.gv2-event-list { min-height: 0; overflow: auto; }
.gv2-setup, .gv2-content, .gv2-main, .gv2-event-list { overscroll-behavior: contain; }
.gv2 .gv2-event { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: minmax(0, 1fr) 18px; width: 100%; height: var(--event-height); gap: 3px 8px; text-align: left; border: 0; border-bottom: 1px solid #42495e; border-radius: 0; padding: 7px 5px; background: transparent; }
.gv2-event time, .gv2-event small { font-size: 10px; color: #aebbd4; }
.gv2-event > span { min-width: 0; }
.gv2-event-route { display: grid; grid-column: 1 / -1; align-content: start; gap: 2px; }
.gv2-event-route small { font-size: 12px; color: #cbd3e8; }
.gv2-event-detail { display: flex; align-items: center; gap: 7px; }
.gv2-event time { flex-shrink: 0; font-variant-numeric: tabular-nums; }
.gv2-event :is(strong, small) { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.gv2-event strong, .gv2-event b { font-size: 12px; }
.gv2-event b { white-space: nowrap; font-variant-numeric: tabular-nums; }
.gv2 [data-resource="hp"] { color: #ff8f9b; }
.gv2 [data-resource="en"] { color: #93caff; }
.gv2 [data-resource="damage"] { color: #f9d86c; }
.gv2-event.is-future { opacity: .45; }
.gv2-log-footer { font-size: 11px; color: #aebbd4; }
@media (max-width: 1000px) {
	.gv2-content { display: block; overflow: auto; }
	.gv2-main { overflow: visible; }
	.gv2-log { height: 400px; margin-top: 10px; }
}
@media (max-width: 600px) {
	.gv2 { width: 100vw; height: 100dvh; border: 0; border-radius: 0; margin: 0; }
	.gv2-header { padding: 8px; }
	.gv2-setup { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: 30dvh; overflow: auto; padding: 8px; }
	.gv2-setup label:first-child { grid-column: 1 / -1; }
	.gv2-setup :is(input, select) { width: 100%; font-size: 16px; }
	.gv2-status { grid-column: 1 / -1; }
	.gv2 :is(button, select) { min-height: 44px; }
	.gv2-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.gv2-transport .gv2-scrub { order: 4; flex-basis: 100%; height: 32px; }
	.gv2-player { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.gv2-content { padding: 8px; }
	.gv2-canvas-wrap { height: 230px; }
}
.gv2 .gv2-legend button::before { content: ''; display: inline-block; width: 8px; height: 8px; margin-right: 6px; border-radius: 50%; background: var(--series-color); }
