:root {
  --stage-radius: 1rem;
}

body {
  min-height: 100dvh;
}

.ar-header-title {
  flex: 1 1 auto;
  min-width: 0;
}

.ar-header-badges {
  flex: 0 0 auto;
  justify-content: flex-end;
}

#statusBadge {
  width: 13rem;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ar-stage {
  position: relative;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  aspect-ratio: 3 / 4;
  border-radius: var(--stage-radius);
  overflow: hidden;
  background: radial-gradient(circle at top, #18243b 0%, #090c14 100%);
}

.ar-video,
.ar-render-host,
.ar-render-host canvas,
.ar-helper-overlay,
.ar-guide-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.ar-video {
  object-fit: cover;
  transform: scaleX(1);
  filter: saturate(1.05) contrast(1.05);
  z-index: 1;
}

.ar-render-host {
  z-index: 2;
}

.ar-render-host canvas {
  display: block;
}

.ar-helper-overlay {
  pointer-events: none;
  z-index: 3;
}

.ar-guide-overlay {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1rem;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(transparent 35%, rgba(0, 0, 0, 0.52) 100%);
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 4;
}

.ar-guide-overlay.hidden {
  opacity: 0;
}

.ar-tuning-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 0.9rem 1rem;
}

.ar-tuning-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.35rem 0.75rem;
  align-items: center;
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(13, 110, 253, 0.12);
  border-radius: 0.9rem;
  background: linear-gradient(180deg, rgba(248, 250, 255, 0.98), rgba(240, 245, 255, 0.92));
}

.ar-tuning-label {
  font-size: 0.92rem;
  font-weight: 600;
  color: #1f2a44;
}

.ar-tuning-value {
  font-variant-numeric: tabular-nums;
  font-size: 0.82rem;
  color: #51607f;
}

.ar-tuning-control input[type="range"] {
  grid-column: 1 / -1;
  width: 100%;
}

@media (min-width: 768px) {
  .ar-stage {
    max-width: 640px;
  }
}

@media (max-width: 575.98px) {
  .ar-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.5rem;
  }

  .ar-header-badges {
    width: 100%;
    justify-content: flex-start;
  }

  #statusBadge {
    width: 11.5rem;
  }
}
