/* Reset */
body, html {
  margin: 0;
  padding: 0;
  height: 100%;
  width: 100%;
  overflow: hidden;
  background: black;
  font-family: Arial, sans-serif;
}

/* Container da câmera */
.camera-container {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

/* Vídeo em tela cheia */
#video {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scaleX(-1); /* flip horizontal para visualização */
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

/* Moldura */
#moldura {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  height: 100%;
  width: auto;
  z-index: 2;
  pointer-events: none;
}

/* Botões da câmera */
.controls {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 15px;
  z-index: 3;
}

.controls button {
  padding: 12px 20px;
  font-size: 18px;
  border: none;
  border-radius: 8px;
  background: #ffffffcc;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

/* Preview */
#preview-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  background: black;
  position: relative;
}

#preview {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

/* Botões do preview */
#botoes-acao {
  display: flex;
  justify-content: center;
  gap: 5px;
  position: absolute;
  bottom: 60px;
  width: 100%;
  z-index: 10;
}

 .btn-acao {
  padding: 8px 12px;          /* menor que antes */
  font-size: 16px;            /* reduzido para caber na tela */
  border: none;
  border-radius: 8px;
  background: #ffffffcc;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
  max-width: 120px;           /* limite de largura */
  display: flex;
  flex-direction: column;      /* ícone em cima, texto embaixo */
  align-items: center;
  justify-content: center;
  text-align: center;
}

.btn-acao .texto {
  white-space: nowrap;
}

#btn-nova {
  display: flex;
  flex-direction: column; /* ícone em cima, texto embaixo */
  align-items: center;
  justify-content: center;
}



