:root {
  --vg-ink: #1d1d1d;
  --vg-muted: #666;
  --vg-brand: #d27d60;
  --vg-brand-dark: #b96549;
  --vg-brand-pale: #fff3e9;
  --vg-line: #eee7e2;
  --vg-bg: #fffaf7;
  --vg-accent: var(--vg-brand);
  --vg-pale: var(--vg-brand-pale);
}

* { box-sizing: border-box; }
body { background: #fff; color: var(--vg-ink); }
.vg-page { overflow: hidden; }
.vg-shell { width: min(1080px, calc(100% - 32px)); margin: 0 auto; }

.vg-hero {
  position: relative;
  padding: 42px 0 28px;
  text-align: center;
  background:
    radial-gradient(circle at 5% 45%, rgba(210,125,96,.11), transparent 22%),
    radial-gradient(circle at 95% 65%, rgba(210,125,96,.07), transparent 21%);
}
.vg-breadcrumbs { margin-bottom: 20px; color: #8a8582; font-size: .8rem; }
.vg-breadcrumbs a { color: var(--vg-brand); text-decoration: none; }
.vg-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--vg-pale);
  color: var(--vg-accent);
  font-size: .76rem;
  font-weight: 750;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.vg-hero h1 {
  max-width: 760px;
  margin: 16px auto 11px;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.05;
  letter-spacing: -.04em;
  font-weight: 850;
}
.vg-hero h1 span { color: var(--vg-accent); }
.vg-hero-copy {
  max-width: 680px;
  margin: 0 auto;
  color: var(--vg-muted);
  font-size: clamp(1rem, 2vw, 1.14rem);
  line-height: 1.6;
}
.vg-trust {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 20px;
  color: #66616a;
  font-size: .86rem;
  font-weight: 650;
}
.vg-trust span { display: inline-flex; align-items: center; gap: 7px; }
.vg-trust i { color: var(--vg-accent); }

.vg-game-card {
  margin-bottom: 56px;
  padding: 16px;
  border: 1px solid var(--vg-line);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 7px 26px rgba(37,29,25,.10);
}
.vg-game-bar {
  min-height: 55px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  padding: 0 3px 14px;
}
.vg-game-name { display: flex; align-items: center; gap: 10px; font-weight: 800; }
.vg-game-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: var(--vg-pale);
  color: var(--vg-accent);
  font-size: 1.05rem;
}
.vg-stats { display: flex; gap: 9px; }
.vg-stat {
  min-width: 82px;
  padding: 7px 11px;
  border-radius: 12px;
  background: #f5f5f6;
  text-align: center;
}
.vg-stat small {
  display: block;
  color: #8b878d;
  font-size: .6rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.vg-stat strong { display: block; font-size: 1rem; font-variant-numeric: tabular-nums; }
.vg-input-status {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #858088;
  font-size: .75rem;
  font-weight: 700;
}
.vg-input-dot { width: 9px; height: 9px; border-radius: 50%; background: #aaa; }
.vg-input-status.live { color: #287a49; }
.vg-input-status.live .vg-input-dot {
  background: #49c979;
  box-shadow: 0 0 0 5px rgba(73,201,121,.13);
  animation: vgPulse 1.35s infinite;
}
@keyframes vgPulse { 50% { box-shadow: 0 0 0 9px rgba(73,201,121,0); } }

.vg-stage {
  position: relative;
  height: min(570px, 66vh);
  min-height: 430px;
  overflow: hidden;
  border-radius: 16px;
  background: #dff3f7;
}
#voiceGameCanvas { display: block; width: 100%; height: 100%; touch-action: none; }
.vg-hud {
  position: absolute;
  z-index: 2;
  left: 14px;
  top: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: calc(100% - 28px);
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.38);
  border-radius: 11px;
  background: rgba(29,29,29,.7);
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  backdrop-filter: blur(8px);
}
.vg-hud strong { color: #ffe29a; }
.vg-meter {
  position: absolute;
  z-index: 2;
  right: 13px;
  top: 13px;
  width: 58px;
  height: calc(100% - 26px);
  border: 1px solid rgba(255,255,255,.45);
  border-radius: 18px;
  background: rgba(29,29,29,.3);
  backdrop-filter: blur(8px);
  pointer-events: none;
}
.vg-meter[hidden] { display: none; }
.vg-meter span {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  color: #fff;
  font-size: .54rem;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.vg-meter .vg-meter-high { top: 11px; }
.vg-meter .vg-meter-low { bottom: 11px; }
.vg-meter-dot {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 28px;
  height: 28px;
  transform: translate(-50%,-50%);
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--vg-accent);
  box-shadow: 0 5px 13px rgba(0,0,0,.2);
  transition: top 70ms linear;
}

.vg-overlay {
  position: absolute;
  z-index: 4;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 22px;
  overflow-y: auto;
  background: linear-gradient(rgba(31,27,25,.12), rgba(31,27,25,.44));
}
.vg-overlay[hidden] { display: none; }
.vg-start-panel {
  width: min(510px, 100%);
  margin: auto;
  padding: 28px;
  border-radius: 22px;
  background: rgba(255,255,255,.97);
  text-align: center;
  box-shadow: 0 20px 55px rgba(29,25,23,.2);
  backdrop-filter: blur(10px);
}
.vg-start-icon {
  width: 68px;
  height: 68px;
  margin: 0 auto 14px;
  display: grid;
  place-items: center;
  border-radius: 20px;
  background: var(--vg-pale);
  color: var(--vg-accent);
  font-size: 1.7rem;
  transform: rotate(-4deg);
}
.vg-start-panel h2 { margin: 0; font-size: 1.8rem; font-weight: 850; letter-spacing: -.035em; }
.vg-start-panel p { max-width: 410px; margin: 9px auto 18px; color: var(--vg-muted); line-height: 1.55; }
.vg-control-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-bottom: 19px;
}
.vg-control-item {
  padding: 12px 9px;
  border: 1px solid var(--vg-line);
  border-radius: 13px;
  background: #fff;
}
.vg-control-item i { display: block; margin-bottom: 5px; color: var(--vg-accent); }
.vg-control-item strong { display: block; font-size: .81rem; }
.vg-control-item small { color: #817c83; font-size: .7rem; }
.vg-btn {
  min-height: 48px;
  padding: 0 23px;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
}
.vg-btn:focus-visible { outline: 3px solid rgba(210,125,96,.3); outline-offset: 3px; }
.vg-btn-primary { background: var(--vg-accent); color: #fff; box-shadow: 0 8px 18px rgba(40,30,25,.16); }
.vg-btn-primary:hover { filter: brightness(.93); transform: translateY(-1px); }
.vg-btn-secondary { background: #efedf0; color: var(--vg-ink); }
.vg-btn-secondary:hover { background: #e3e0e4; transform: translateY(-1px); }
.vg-start-note { margin-top: 12px; color: #8b868c; font-size: .69rem; }

.vg-calibration {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 50%;
  transform: translate(-50%,-50%);
  width: min(390px, calc(100% - 100px));
  padding: 17px 18px;
  border-radius: 15px;
  background: rgba(255,255,255,.95);
  color: var(--vg-ink);
  text-align: center;
  box-shadow: 0 13px 38px rgba(0,0,0,.2);
  backdrop-filter: blur(8px);
  pointer-events: none;
}
.vg-calibration[hidden] { display: none; }
.vg-calibration i { color: var(--vg-accent); margin-right: 6px; }
.vg-calibration strong { display: block; }
.vg-calibration small { display: block; margin-top: 5px; color: var(--vg-muted); font-size: .72rem; }

.vg-results-overlay { align-items: start; background: rgba(29,27,31,.84); backdrop-filter: blur(8px); }
.vg-results {
  width: min(760px, 100%);
  margin: auto;
  overflow: hidden;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 22px 65px rgba(0,0,0,.35);
}
.vg-result-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 17px;
  padding: 23px 27px;
  border-bottom: 1px solid var(--vg-line);
  background: linear-gradient(135deg, var(--vg-pale), #fff);
}
.vg-result-medal {
  width: 68px;
  height: 68px;
  display: grid;
  place-items: center;
  border-radius: 20px;
  background: var(--vg-accent);
  color: #fff;
  font-size: 1.6rem;
  transform: rotate(-4deg);
}
.vg-result-copy small { color: var(--vg-accent); font-size: .69rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.vg-result-copy h2 { margin: 2px 0 0; font-size: 1.65rem; font-weight: 850; letter-spacing: -.035em; }
.vg-final-score { text-align: right; }
.vg-final-score strong { display: block; color: var(--vg-accent); font-size: 2.2rem; font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.vg-final-score span { color: var(--vg-muted); font-size: .68rem; font-weight: 700; }
.vg-result-body { display: grid; grid-template-columns: .85fr 1.15fr; gap: 23px; padding: 23px 27px 27px; }
.vg-result-metrics { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 15px; }
.vg-result-metric { padding: 11px; border-radius: 12px; background: #f6f5f5; }
.vg-result-metric small { display: block; color: #827d84; font-size: .63rem; font-weight: 750; text-transform: uppercase; }
.vg-result-metric strong { font-size: 1.06rem; }
.vg-name-label { display: block; margin-bottom: 7px; color: #565158; font-size: .74rem; font-weight: 750; }
.vg-name-row { display: flex; gap: 8px; }
.vg-name-row input {
  min-width: 0;
  width: 100%;
  height: 45px;
  padding: 0 12px;
  border: 1.5px solid var(--vg-line);
  border-radius: 11px;
  font: inherit;
  outline: none;
}
.vg-name-row input:focus { border-color: var(--vg-accent); box-shadow: 0 0 0 3px rgba(210,125,96,.10); }
.vg-name-row .vg-btn { min-height: 45px; padding: 0 15px; box-shadow: none; }
.vg-saved { min-height: 18px; margin: 5px 0 0; color: #398557; font-size: .69rem; font-weight: 700; }
.vg-result-actions { display: flex; gap: 8px; margin-top: 10px; }
.vg-result-actions .vg-btn { flex: 1; min-height: 43px; }
.vg-leader-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.vg-leader-head h3 { margin: 0; font-size: .98rem; font-weight: 850; }
.vg-leader-head span { color: #8b858b; font-size: .64rem; }
.vg-leaderboard { margin: 0; padding: 0; overflow: hidden; border: 1px solid var(--vg-line); border-radius: 14px; list-style: none; }
.vg-leaderboard li {
  min-height: 40px;
  display: grid;
  grid-template-columns: 31px 1fr auto;
  align-items: center;
  gap: 7px;
  padding: 0 11px;
  border-bottom: 1px solid #eee9e6;
  font-size: .8rem;
}
.vg-leaderboard li:last-child { border-bottom: 0; }
.vg-leaderboard li.is-player { background: var(--vg-pale); }
.vg-rank { color: #99939a; font-weight: 850; }
.vg-leaderboard li:nth-child(1) .vg-rank { color: #c68d15; }
.vg-leaderboard li:nth-child(2) .vg-rank { color: #858e9d; }
.vg-leaderboard li:nth-child(3) .vg-rank { color: #a86a3c; }
.vg-player-name { overflow: hidden; font-weight: 720; text-overflow: ellipsis; white-space: nowrap; }
.vg-player-score { font-weight: 850; font-variant-numeric: tabular-nums; }

.vg-content { padding: 28px 0 72px; }
.vg-content-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(34px, 7vw, 82px); }
.vg-section-label { color: var(--vg-accent); font-size: .74rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.vg-content h2, .vg-tips h2, .vg-faq h2 {
  margin: 8px 0 14px;
  font-size: clamp(1.7rem, 4vw, 2.65rem);
  line-height: 1.08;
  letter-spacing: -.035em;
  font-weight: 850;
}
.vg-content p { color: var(--vg-muted); line-height: 1.72; }
.vg-steps { display: grid; gap: 11px; }
.vg-step {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 13px;
  padding: 16px;
  border: 1px solid var(--vg-line);
  border-radius: 15px;
  background: #fff;
}
.vg-step-num { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; background: var(--vg-accent); color: #fff; font-weight: 850; }
.vg-step h3 { margin: 0 0 3px; font-size: .93rem; font-weight: 800; }
.vg-step p { margin: 0; font-size: .83rem; line-height: 1.52; }
.vg-tips { padding: 62px 0; border-block: 1px solid #f0e5de; background: var(--vg-pale); text-align: center; }
.vg-tip-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 13px; margin-top: 27px; text-align: left; }
.vg-tip { padding: 21px; border: 1px solid #eee2db; border-radius: 15px; background: #fff; }
.vg-tip i { color: var(--vg-accent); font-size: 1.18rem; }
.vg-tip h3 { margin: 10px 0 5px; font-size: .96rem; font-weight: 800; }
.vg-tip p { margin: 0; color: var(--vg-muted); font-size: .83rem; line-height: 1.58; }
.vg-more { padding: 68px 0 20px; }
.vg-more h2 { text-align: center; margin: 0 0 23px; font-size: 1.8rem; font-weight: 850; }
.vg-more-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; }
.vg-more-card { padding: 17px; border: 1px solid var(--vg-line); border-radius: 14px; color: inherit; text-decoration: none; background: #fff; transition: transform .15s ease, box-shadow .15s ease; }
.vg-more-card:hover { color: inherit; text-decoration: none; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(34,27,23,.08); }
.vg-more-card i { color: var(--vg-brand); }
.vg-more-card strong { display: block; margin: 8px 0 3px; font-size: .9rem; }
.vg-more-card span { color: var(--vg-muted); font-size: .74rem; line-height: 1.4; }
.vg-faq { max-width: 820px; padding: 68px 0 82px; }
.vg-faq { text-align: center; }
.vg-faq details { border-bottom: 1px solid var(--vg-line); text-align: left; }
.vg-faq summary { position: relative; padding: 19px 35px 19px 0; list-style: none; cursor: pointer; font-weight: 800; }
.vg-faq summary::-webkit-details-marker { display: none; }
.vg-faq summary:after { content: "+"; position: absolute; right: 4px; top: 14px; color: var(--vg-accent); font-size: 1.5rem; }
.vg-faq details[open] summary:after { content: "−"; }
.vg-faq details p { margin: -6px 35px 18px 0; color: var(--vg-muted); line-height: 1.65; }

@media (max-width: 820px) {
  .vg-game-bar { grid-template-columns: 1fr auto; }
  .vg-input-status { display: none; }
  .vg-stage { height: 60vh; min-height: 410px; }
  .vg-result-body, .vg-content-grid { grid-template-columns: 1fr; }
  .vg-tip-grid { grid-template-columns: 1fr; }
  .vg-more-grid { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 560px) {
  .vg-shell { width: min(100% - 18px,1080px); }
  .vg-hero { padding-top: 30px; }
  .vg-game-card { padding: 8px; border-radius: 17px; }
  .vg-stage { min-height: 390px; border-radius: 12px; }
  .vg-game-name span { display: none; }
  .vg-stat { min-width: 68px; padding: 6px 8px; }
  .vg-meter { width: 47px; }
  .vg-calibration { width: calc(100% - 62px); }
  .vg-start-panel { padding: 22px 17px; }
  .vg-control-summary { gap: 7px; }
  .vg-result-head { grid-template-columns: auto 1fr; padding: 18px; }
  .vg-result-medal { width: 56px; height: 56px; border-radius: 16px; }
  .vg-final-score { grid-column: 1/-1; display: flex; justify-content: center; align-items: baseline; gap: 7px; }
  .vg-final-score strong { font-size: 1.9rem; }
  .vg-result-body { padding: 18px; gap: 16px; }
  .vg-more-grid { grid-template-columns: 1fr; }
}
