* { box-sizing: border-box; }
html, body {
  margin: 0;
  min-height: 100%;
  background: #050505;
}
body {
  display: grid;
  place-items: start center;
  overflow: auto;
  font-family: Arial, Helvetica, sans-serif;
}
.dashboard {
  position: relative;
  width: 900px;
  height: 1600px;
  overflow: hidden;
  background: #000;
  isolation: isolate;
}
.dashboard-bg {
  position: absolute;
  inset: 0;
  width: 900px;
  height: 1600px;
  object-fit: cover;
  user-select: none;
  pointer-events: none;
  z-index: 0;
}
.editable {
  outline: none;
  cursor: text;
}
.editable:focus {
  filter: drop-shadow(0 0 6px rgba(255, 185, 35, .9));
}

/* Tipografía general */
.lap-title,
.best-title,
.sector-row,
.seller-name,
.metric-name,
.metric-cell,
.points,
.prize,
.speed,
.kmh,
.status-line {
  font-family: "Arial Black", Impact, Haettenschweiler, "Roboto Condensed", Arial, sans-serif;
  text-transform: uppercase;
}

/* HUD superior izquierdo */
.lap-hud {
  position: absolute;
  z-index: 12;
  left: 28px;
  top: 254px;
  width: 112px;
  height: 96px;
  color: #fff;
  text-align: left;
  text-shadow: 0 2px 4px rgba(0,0,0,.95);
}
.lap-title {
  position: absolute;
  left: 6px;
  top: 8px;
  font-size: 18px;
  line-height: 1;
  letter-spacing: .5px;
}
.lap-value {
  position: absolute;
  left: 6px;
  top: 31px;
  width: 100px;
  font-size: 20px;
  line-height: 22px;
  font-weight: 900;
  color: #fff;
}
.best-title {
  position: absolute;
  left: 6px;
  top: 58px;
  font-size: 11px;
  line-height: 1;
  color: #cfcfcf;
  letter-spacing: .4px;
}
.best-value {
  position: absolute;
  left: 6px;
  top: 73px;
  width: 108px;
  font-size: 19px;
  line-height: 20px;
  font-weight: 900;
  color: #ff6d22;
  text-shadow: 0 0 8px rgba(255, 100, 20, .75), 0 2px 4px #000;
}

/* HUD superior derecho */
.sector-hud {
  position: absolute;
  z-index: 12;
  left: 700px;
  top: 303px;
  width: 162px;
  height: 96px;
  color: #fff;
  text-shadow: 0 2px 4px rgba(0,0,0,.95);
}
.sector-row {
  height: 29px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 17px;
  line-height: 1;
  letter-spacing: .3px;
}
.sector-row span {
  width: 44px;
  text-align: right;
  font-weight: 900;
}
.sector-row:nth-child(n+2) span { color: #ff7922; }
.sector-row b {
  min-width: 94px;
  text-align: right;
  font-weight: 900;
  color: #f2f2f2;
  font-style: normal;
}

/* Participantes */
.seller {
  position: absolute;
  pointer-events: none;
}
.seller-photo {
  position: absolute;
  z-index: 6;
  overflow: visible;
  pointer-events: none;
  background: transparent;
  box-shadow: none;
}
.seller-photo::before {
  content: attr(data-initials);
  position: absolute;
  left: 50%;
  top: 40%;
  transform: translate(-50%, -50%);
  width: 112px;
  height: 112px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,.04));
  border: 2px solid rgba(255,255,255,.22);
  color: rgba(255,255,255,.9);
  font-family: "Arial Black", Impact, sans-serif;
  font-size: 42px;
  letter-spacing: 1px;
  text-shadow: 0 2px 4px #000;
}
.seller-photo.has-image::before { display: none; }
.seller-photo img {
  position: absolute;
  left: 50%;
  bottom: 0;
  display: block;
  width: auto;
  height: auto;
  transform: translateX(-50%);
  filter: contrast(1.04) saturate(1.03) drop-shadow(0 20px 18px rgba(0,0,0,.75));
}

/* Ajustes individuales para que los PNG transparentes floten sobre cada podio. */
.seller-p1 .seller-photo img {
  width: 296px;
  max-width: none;
  bottom: 0;
  -webkit-clip-path: inset(0 0 180px 0);
  clip-path: inset(0 0 180px 0);
}
.seller-p2 .seller-photo img,
.seller-p3 .seller-photo img {
  width: 214px;
  max-width: none;
  bottom: 0;
  -webkit-clip-path: inset(0 0 86px 0);
  clip-path: inset(0 0 86px 0);
}
.seller-p1 { left: 0; top: 0; width: 900px; height: 1600px; }
.seller-p2 { left: 0; top: 0; width: 900px; height: 1600px; }
.seller-p3 { left: 0; top: 0; width: 900px; height: 1600px; }

.seller-p1 .seller-photo {
  left: 286px;
  top: 155px;
  width: 330px;
  height: 655px;
  clip-path: none;
}
.seller-p2 .seller-photo {
  left: 66px;
  top: 330px;
  width: 242px;
  height: 436px;
  clip-path: none;
}
.seller-p3 .seller-photo {
  left: 592px;
  top: 330px;
  width: 195px;
  height: 436px;
  clip-path: none;
}
.seller-name {
  position: absolute;
  z-index: 14;
  pointer-events: auto;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
  font-style: italic;
  text-align: center;
  letter-spacing: .7px;
  text-shadow:
    0 0 1px #fff,
    0 0 8px rgba(255,255,255,.24),
    0 3px 5px rgba(0,0,0,.95);
}
.seller-p1 .seller-name {
  left: 300px;
  top: 674px;
  width: 300px;
  height: 82px;
  font-size: 39px;
  line-height: 42px;
}
.seller-p2 .seller-name {
  left: 57px;
  top: 690px;
  width: 236px;
  height: 76px;
  font-size: 30px;
  line-height: 33px;
}
.seller-p3 .seller-name {
  left: 606px;
  top: 690px;
  width: 237px;
  height: 76px;
  font-size: 30px;
  line-height: 33px;
}


.podium-floating-overlay {
  position: absolute;
  left: 0;
  top: 609px;
  width: 900px;
  height: 172px;
  object-fit: contain;
  pointer-events: none;
  z-index: 10;
}

/* Tabla */
.metrics {
  position: absolute;
  z-index: 12;
  left: 38px;
  top: 830px;
  width: 824px;
  height: 430px;
}
.metric-labels,
.metric-values {
  position: absolute;
  inset: 0;
}
.metric-row-label,
.metric-cell {
  position: absolute;
  height: 42px;
  display: flex;
  align-items: center;
  font-weight: 900;
  line-height: 1;
  text-shadow: 0 2px 4px #000, 0 0 5px rgba(255,255,255,.18);
}
.metric-row-label {
  left: 18px;
  width: 250px;
  color: #f3f3f3;
  justify-content: flex-start;
  gap: 12px;
  font-size: 19px;
  letter-spacing: .1px;
}
.metric-icon {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 34px;
  font-size: 21px;
  border-radius: 8px;
  color: var(--icon-color, #ffaf24);
  filter: drop-shadow(0 0 5px currentColor);
}
.metric-name { white-space: nowrap; }
.metric-cell {
  justify-content: center;
  color: #fff;
  font-size: 25px;
  letter-spacing: .2px;
  pointer-events: auto;
  text-align: center;
  white-space: nowrap;
}
.metric-cell[data-col="0"] { left: 282px; width: 176px; }
.metric-cell[data-col="1"] { left: 462px; width: 182px; }
.metric-cell[data-col="2"] { left: 646px; width: 178px; }
.metric-cell:focus,
.metric-row-label:focus {
  background: rgba(255, 191, 40, .13);
  box-shadow: inset 0 0 12px rgba(255, 191, 40, .35);
}

/* Puntos y premios */
.score {
  position: absolute;
  inset: 0;
  z-index: 14;
  pointer-events: none;
}
.points,
.prize {
  position: absolute;
  pointer-events: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-style: italic;
  line-height: 1;
  letter-spacing: 1px;
}
.points {
  top: 1275px;
  height: 57px;
  font-size: 39px;
  letter-spacing: 0;
  white-space: nowrap;
}
.points-p1 { left: 319px; width: 178px; }
.points-p2 { left: 501px; width: 163px; }
.points-p3 { left: 665px; width: 192px; }
.prize {
  top: 1350px;
  height: 52px;
  font-size: 31px;
  letter-spacing: 0;
  white-space: nowrap;
}
.prize-p1 { left: 310px; width: 202px; }
.prize-p2 { left: 506px; width: 157px; }
.prize-p3 { left: 673px; width: 173px; }
.accent-gold {
  color: #ffcf48;
  text-shadow: 0 0 12px rgba(255, 202, 56, .72), 0 2px 4px #000;
}
.accent-silver {
  color: #f4f4f4;
  text-shadow: 0 0 9px rgba(255,255,255,.5), 0 2px 4px #000;
}
.accent-bronze {
  color: #ff9448;
  text-shadow: 0 0 11px rgba(255, 105, 35, .58), 0 2px 4px #000;
}

/* Inferior */
.bottom-hud {
  position: absolute;
  inset: 0;
  z-index: 15;
  pointer-events: none;
}
.speed {
  position: absolute;
  left: 58px;
  top: 1478px;
  width: 142px;
  height: 62px;
  display: grid;
  place-items: center;
  pointer-events: auto;
  color: #ff671e;
  font-size: 54px;
  font-weight: 900;
  font-style: italic;
  line-height: 1;
  text-shadow: 0 0 13px rgba(255, 96, 21, .75), 0 3px 4px #000;
}
.kmh {
  position: absolute;
  left: 91px;
  top: 1536px;
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: 1.4px;
  text-shadow: 0 2px 4px #000;
}
.status-panel {
  position: absolute;
  left: 673px;
  top: 1468px;
  width: 170px;
  height: 78px;
  pointer-events: auto;
}
.status-line {
  display: flex;
  align-items: center;
  height: 26px;
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  text-shadow: 0 2px 4px #000;
}
.status-line span { width: 48px; }
.dot {
  width: 14px;
  height: 14px;
  display: inline-block;
  border-radius: 50%;
  background: #353535;
}
.dot.on {
  background: #1be219;
  box-shadow: 0 0 12px rgba(38, 255, 0, .9);
}
.bars {
  display: inline-grid;
  grid-auto-flow: column;
  gap: 3px;
  height: 14px;
  align-items: stretch;
}
.bars i {
  width: 11px;
  height: 14px;
  display: block;
  transform: skew(-12deg);
  border-radius: 1px;
  background: rgba(255,255,255,.18);
}
.bars-ers i.on { background: #46ec1e; box-shadow: 0 0 7px rgba(30,255,40,.75); }
.bars-fuel i.on { background: #ffae1d; box-shadow: 0 0 7px rgba(255,174,29,.68); }
