body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 10px;
    background: #f2f2f2;
}

/* APP CONTAINER (NEU WICHTIG) */
.app {
    max-width: 420px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* HEADER */
h1 {
    font-size: 20px;
    margin: 10px 0;
    text-align: center;
}

/* INFO */
#meterInfo {
    text-align: center;
    font-weight: bold;
    color: green;
}

/* =========================
   KAMERA BLOCK (KLEIN!)
========================= */
#cameraContainer {
    width: 100%;
    height: 160px;   /* WICHTIG: begrenzt */
    overflow: hidden;
    border: 3px solid red;
    border-radius: 10px;
    background: black;
    position: relative;
}
/* OCR-Button */
#readOCR {
    display: none;
}

/* VIDEO sauber skalieren */
#video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* dunkle Bereiche oben + unten */
.shade {
    position: absolute;
    left: 0;
    width: 100%;
    background: rgba(0,0,0,0.55);
    pointer-events: none;
}

/* oben */
.shade.top {
    top: 0;
    height: 31%;
}

/* unten */
.shade.bottom {
    bottom: 0;
    height: 33%;
}

/* links */
.shade.left {
    top: 31%;
    width: 25%;
    height: 36%;
}

/* rechts */
.shade.right {
    top: 31%;
    left: 75%;
    width: 25%;
    height:36%;
}

/* SCAN HILFE */
#scanGuide {
    position: absolute;
    top: 49%;
    left: 25%;
    width: 50%;
    height: 38%;
    transform: translateY(-50%);
    border: 2px solid red;
    pointer-events: none;
    box-sizing: border-box;
}

/* =========================
   CONTROLS
========================= */
button {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    border: none;
    border-radius: 8px;
    background: #0066cc;
    color: white;
}

/* INPUT */
input {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    text-align: center;
}

/* STATUS */
#status {
    text-align: center;
    font-weight: bold;
}

/* CANVAS VERSTECKEN (WICHTIG!) */
canvas {
    display: none;
}

/* Listbox */

#candidateBox {
    width: 90%;
    max-width: 300px;
    margin: 10px auto;
    text-align: left;
    font-size: 16px;
}

.candidate {
    padding: 6px;
    margin: 3px 0;
    background: #fff;
    border-radius: 6px;
    cursor: pointer;
}

.candidate.top {
    font-weight: bold;
    background: #dff0d8;
}
/* DEBUG BOX */
#debugBox {

    font-size: 12px;
    background: #222;
    color: #00ff00;
    padding: 6px;
    border-radius: 6px;
    font-family: monospace;
    white-space: pre-line;
}
