.matchScene{
  position:relative;
  height:320px;
  border-radius:16px;
  overflow:hidden;
  border:1px solid rgba(15,23,42,.10);
  background:
    radial-gradient(circle at 30% 20%, rgba(59,130,246,.10), transparent 55%),
    radial-gradient(circle at 70% 70%, rgba(34,197,94,.08), transparent 60%),
    linear-gradient(180deg, rgba(15,23,42,.02), rgba(15,23,42,.05));
}

/* global scene glow when flame is active */
.sceneGlow{
  position:absolute;
  inset:-30px;
  background: radial-gradient(circle at 55% 60%, rgba(251,191,36,.0), transparent 55%);
  opacity:0;
  transition: opacity .25s ease;
  pointer-events:none;
}
.sceneGlow.active{
  opacity:1;
  background: radial-gradient(circle at 55% 60%, rgba(251,191,36,.22), transparent 60%);
}

/* match positioning */
.matchWrap{
  position:absolute;
  left:50%;
  top:52%;
  transform:translate(-50%, -50%);
  width:260px;
  height:120px;
}

/* stick */
.matchStick{
  position:absolute;
  left:30px;
  top:54px;
  width:200px;
  height:14px;
  border-radius:999px;
  background: linear-gradient(90deg, rgba(226,232,240,.95), rgba(148,163,184,.95));
  box-shadow: inset 0 -2px 0 rgba(15,23,42,.10);
}

/* head */
.matchHead{
  position:absolute;
  right:18px;
  top:44px;
  width:34px;
  height:34px;
  border-radius:14px;
  background: linear-gradient(135deg, rgba(239,68,68,.85), rgba(251,191,36,.55));
  box-shadow: 0 14px 24px rgba(15,23,42,.18);
  transform: rotate(6deg);
  transition: filter .2s ease, transform .2s ease;
}
.matchHead.burned{
  filter: saturate(.3) brightness(.8);
  transform: rotate(6deg) scale(.98);
}

/* flame */
.flame{
  position:absolute;
  right:6px;
  top:14px;
  width:70px;
  height:90px;
  opacity:0;
  transform: translateY(10px) scale(.85);
  transition: opacity .2s ease, transform .2s ease;
  pointer-events:none;
}
.flame.active{
  opacity:1;
  transform: translateY(0) scale(1);
}

/* flame layers */
.flame::before,
.flame::after{
  content:"";
  position:absolute;
  inset:0;
  margin:auto;
  border-radius: 60% 60% 60% 60%;
  filter: blur(.2px);
  animation: flicker 1.05s ease-in-out infinite;
}
.flame::before{
  width:56px;
  height:76px;
  left:8px;
  top:8px;
  background: radial-gradient(circle at 50% 30%, rgba(255,255,255,.95), rgba(251,191,36,.95) 35%, rgba(249,115,22,.85) 70%, rgba(239,68,68,.55));
  box-shadow: 0 0 28px rgba(251,191,36,.45);
}
.flame::after{
  width:38px;
  height:56px;
  left:16px;
  top:20px;
  background: radial-gradient(circle at 50% 30%, rgba(255,255,255,.95), rgba(251,191,36,.85) 40%, rgba(59,130,246,.22));
  opacity:.9;
  animation-duration: .85s;
}

@keyframes flicker{
  0%,100%{ transform: rotate(-3deg) scale(1); }
  50%{ transform: rotate(3deg) scale(1.03); }
}

/* sparks burst */
.sparks{
  position:absolute;
  right:10px;
  top:34px;
  width:80px;
  height:80px;
  pointer-events:none;
}
.spark{
  position:absolute;
  left:40px;
  top:40px;
  width:6px;
  height:6px;
  border-radius:999px;
  background: rgba(251,191,36,.95);
  box-shadow: 0 0 14px rgba(251,191,36,.65);
  animation: sparkOut .55s ease-out forwards;
}
@keyframes sparkOut{
  from{ transform: translate(0,0) scale(1); opacity:1; }
  to{ transform: translate(var(--dx), var(--dy)) scale(.6); opacity:0; }
}

/* status text */
.status{
  position:absolute;
  left:14px;
  bottom:14px;
  padding:10px 12px;
  border-radius:14px;
  background: rgba(255,255,255,.65);
  border:1px solid rgba(15,23,42,.10);
  color:#0f172a;
  font-weight:900;
  font-size:13px;
}

/* meter block */
.lightMeter{
  position:absolute;
  right:14px;
  bottom:14px;
  width:min(260px, 44vw);
  padding:10px 12px;
  border-radius:14px;
  background: rgba(255,255,255,.65);
  border:1px solid rgba(15,23,42,.10);
}

/* info box (right panel) */
.infoBox{
  margin-top:14px;
  border-radius:14px;
  border:1px solid rgba(15,23,42,.10);
  background: rgba(255,255,255,.7);
  padding:10px 12px;
}
.infoRow{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding:6px 0;
  border-bottom:1px dashed rgba(15,23,42,.10);
}
.infoRow:last-child{ border-bottom:0; }

.tag{
  font-size:12px;
  font-weight:1000;
  color:#334155;
  background: rgba(15,23,42,.05);
  border:1px solid rgba(15,23,42,.08);
  padding:6px 10px;
  border-radius:999px;
}
.val{
  font-size:13px;
  color: var(--rr-muted);
  font-weight:800;
}
